<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Piotr Zaniewicz</title>
	<atom:link href="http://piotr.eldora.pl/feed" rel="self" type="application/rss+xml" />
	<link>http://piotr.eldora.pl</link>
	<description>Ideas not to be forgotten...</description>
	<lastBuildDate>Wed, 04 Nov 2009 10:00:28 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.6</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Wysyłanie SMS przez bramkę mBox orange.pl &#8211; wykorzystanie php+curl</title>
		<link>http://piotr.eldora.pl/2009/09/18/wysylanie-sms-przez-bramke-mbox-orange-pl-wykorzystanie-phpcurl</link>
		<comments>http://piotr.eldora.pl/2009/09/18/wysylanie-sms-przez-bramke-mbox-orange-pl-wykorzystanie-phpcurl#comments</comments>
		<pubDate>Fri, 18 Sep 2009 01:45:46 +0000</pubDate>
		<dc:creator>Piotr Zaniewicz</dc:creator>
				<category><![CDATA[General]]></category>

		<guid isPermaLink="false">http://piotr.eldora.pl/?p=91</guid>
		<description><![CDATA[Trochę uporządkowałem skrypty i postanowiłem udostępnić skrypt do wysyłania sms&#8217;ów przez bramkę mBox orange.pl.
Jestem ciekawy ewentualnych ulepszeń, więc jak coś to proszę podsyłać nowe wersje  
UPDATE:
Skrypt został wzbogacony o możliwość wysyłania dowolnie długich wiadomości. Dzieli wpisaną wiadomość na 640 znaków i wysyła funkcją jako osobne smsy.
Ponadto, końcowy stan smsów jest pobierany przez Xpath.
Plik PHPS
]]></description>
			<content:encoded><![CDATA[<p>Trochę uporządkowałem skrypty i postanowiłem udostępnić skrypt do wysyłania sms&#8217;ów przez bramkę mBox orange.pl.</p>
<p>Jestem ciekawy ewentualnych ulepszeń, więc jak coś to proszę podsyłać nowe wersje <img src='http://piotr.eldora.pl/weblog/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </p>
<p><strong><em>UPDATE:</em></strong><br />
Skrypt został wzbogacony o możliwość wysyłania dowolnie długich wiadomości. Dzieli wpisaną wiadomość na 640 znaków i wysyła funkcją jako osobne smsy.<br />
Ponadto, końcowy stan smsów jest pobierany przez Xpath.</p>
<p><a href="http://piotr.eldora.pl/.downloads/mbox_sender.phps">Plik PHPS</a></p>
]]></content:encoded>
			<wfw:commentRss>http://piotr.eldora.pl/2009/09/18/wysylanie-sms-przez-bramke-mbox-orange-pl-wykorzystanie-phpcurl/feed</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
		<item>
		<title>Spamassassin + vpopmail + sa-learn + learning from IMAP folders</title>
		<link>http://piotr.eldora.pl/2009/05/17/spamassassin-vpopmail-sa-learn-learning-from-imap-folders</link>
		<comments>http://piotr.eldora.pl/2009/05/17/spamassassin-vpopmail-sa-learn-learning-from-imap-folders#comments</comments>
		<pubDate>Sat, 16 May 2009 22:37:33 +0000</pubDate>
		<dc:creator>Piotr Zaniewicz</dc:creator>
				<category><![CDATA[Linux]]></category>

		<guid isPermaLink="false">http://piotr.eldora.pl/?p=79</guid>
		<description><![CDATA[Below is a quick solution to making spamassassin learn from specific IMAP folders. Script represents a daily cron script and I just used sudo vpopmail (has to be the same as your spamd user) to simplify things. You probably should use user specific crontab&#8230;

1
2
3
4
5
#!/bin/bash
for F in `find /home/vpopmail/domains -type d -name '.Junk' -print`;
do sudo -H [...]]]></description>
			<content:encoded><![CDATA[<p>Below is a quick solution to making spamassassin learn from specific IMAP folders. Script represents a daily cron script and I just used <em>sudo vpopmail</em> (has to be the same as your spamd user) to simplify things. You probably should use user specific crontab&#8230;</p>

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>1
2
3
4
5
</pre></td><td class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #666666; font-style: italic;">#!/bin/bash</span>
<span style="color: #000000; font-weight: bold;">for</span> F <span style="color: #000000; font-weight: bold;">in</span> <span style="color: #000000; font-weight: bold;">`</span><span style="color: #c20cb9; font-weight: bold;">find</span> <span style="color: #000000; font-weight: bold;">/</span>home<span style="color: #000000; font-weight: bold;">/</span>vpopmail<span style="color: #000000; font-weight: bold;">/</span>domains <span style="color: #660033;">-type</span> d <span style="color: #660033;">-name</span> <span style="color: #ff0000;">'.Junk'</span> -print<span style="color: #000000; font-weight: bold;">`</span>;
<span style="color: #000000; font-weight: bold;">do</span> <span style="color: #c20cb9; font-weight: bold;">sudo</span> <span style="color: #660033;">-H</span> <span style="color: #660033;">-u</span> vpopmail <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>bin<span style="color: #000000; font-weight: bold;">/</span>sa-learn <span style="color: #660033;">--spam</span> <span style="color: #007800;">$F</span><span style="color: #000000; font-weight: bold;">/</span>cur<span style="color: #000000; font-weight: bold;">/*</span> <span style="color: #000000; font-weight: bold;">&amp;&gt;</span> <span style="color: #000000; font-weight: bold;">/</span>dev<span style="color: #000000; font-weight: bold;">/</span>null;
<span style="color: #c20cb9; font-weight: bold;">rm</span> <span style="color: #660033;">-f</span> <span style="color: #007800;">$F</span><span style="color: #000000; font-weight: bold;">/</span>cur<span style="color: #000000; font-weight: bold;">/*</span>;
<span style="color: #000000; font-weight: bold;">done</span>;</pre></td></tr></table></div>

]]></content:encoded>
			<wfw:commentRss>http://piotr.eldora.pl/2009/05/17/spamassassin-vpopmail-sa-learn-learning-from-imap-folders/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>php strpos array</title>
		<link>http://piotr.eldora.pl/2009/03/26/php-strpos-array</link>
		<comments>http://piotr.eldora.pl/2009/03/26/php-strpos-array#comments</comments>
		<pubDate>Thu, 26 Mar 2009 05:57:20 +0000</pubDate>
		<dc:creator>Piotr Zaniewicz</dc:creator>
				<category><![CDATA[Web]]></category>

		<guid isPermaLink="false">http://piotr.eldora.pl/?p=65</guid>
		<description><![CDATA[I needed a PHP function to check whether a string contained one of the array values. As we know strpos does&#8217;t accept input as an array so I had to tweak it  bit. Below is an example of what I did:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
function strpos_array&#40;$string, $values&#41; &#123;
    $hits = 0; //will give number of values [...]]]></description>
			<content:encoded><![CDATA[<p>I needed a PHP function to check whether a string contained one of the array values. As we know strpos does&#8217;t accept input as an array so I had to tweak it  bit. Below is an example of what I did:</p>

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
</pre></td><td class="code"><pre class="php" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">function</span> strpos_array<span style="color: #009900;">&#40;</span><span style="color: #000088;">$string</span><span style="color: #339933;">,</span> <span style="color: #000088;">$values</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
    <span style="color: #000088;">$hits</span> <span style="color: #339933;">=</span> <span style="color: #cc66cc;">0</span><span style="color: #339933;">;</span> <span style="color: #666666; font-style: italic;">//will give number of values found in a string</span>
    <span style="color: #b1b100;">foreach</span> <span style="color: #009900;">&#40;</span><span style="color: #000088;">$values</span> <span style="color: #b1b100;">as</span> <span style="color: #000088;">$try</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
        <span style="color: #000088;">$pos</span> <span style="color: #339933;">=</span> <span style="color: #990000;">strpos</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$string</span><span style="color: #339933;">,</span> <span style="color: #000088;">$try</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
        <span style="color: #b1b100;">if</span> <span style="color: #009900;">&#40;</span><span style="color: #000088;">$pos</span> <span style="color: #339933;">!==</span> <span style="color: #009900; font-weight: bold;">false</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#123;</span>
            <span style="color: #000088;">$hits</span><span style="color: #339933;">++;</span> <span style="color: #666666; font-style: italic;">// you can do array_push here to get the values</span>
        <span style="color: #009900;">&#125;</span>
    <span style="color: #009900;">&#125;</span>
    <span style="color: #b1b100;">if</span> <span style="color: #009900;">&#40;</span><span style="color: #000088;">$hits</span><span style="color: #339933;">==</span><span style="color: #cc66cc;">0</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span> <span style="color: #666666; font-style: italic;">//if none value from array was found returns false</span>
        <span style="color: #b1b100;">return</span> <span style="color: #009900; font-weight: bold;">false</span><span style="color: #339933;">;</span>
    <span style="color: #009900;">&#125;</span>
    <span style="color: #b1b100;">else</span> <span style="color: #009900;">&#123;</span> <span style="color: #666666; font-style: italic;">//I just needed a simple true/false boolean</span>
       <span style="color: #b1b100;">return</span> <span style="color: #009900; font-weight: bold;">true</span><span style="color: #339933;">;</span>
    <span style="color: #009900;">&#125;</span>
<span style="color: #009900;">&#125;</span></pre></td></tr></table></div>

]]></content:encoded>
			<wfw:commentRss>http://piotr.eldora.pl/2009/03/26/php-strpos-array/feed</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>FPDF polskie wolne czcionki</title>
		<link>http://piotr.eldora.pl/2009/01/19/fpdf-polskie-wolne-czcionki</link>
		<comments>http://piotr.eldora.pl/2009/01/19/fpdf-polskie-wolne-czcionki#comments</comments>
		<pubDate>Mon, 19 Jan 2009 11:13:26 +0000</pubDate>
		<dc:creator>Piotr Zaniewicz</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[Web]]></category>
		<category><![CDATA[linux fpdf gpl wolne]]></category>

		<guid isPermaLink="false">http://piotr.eldora.pl/?p=39</guid>
		<description><![CDATA[Postanowiłem wreszcie trochę uporządkować czcionki używane do generowania dokumentów pdf oraz obrazków wykorzystujących czcionki ttf. Załączam zestaw gotowej do zainstalowania czytelnej czcionki z pakietu liberation-fonts. Które są upowszechnione na licencji GPL.
Pobierz
]]></description>
			<content:encoded><![CDATA[<p>Postanowiłem wreszcie trochę uporządkować czcionki używane do generowania dokumentów pdf oraz obrazków wykorzystujących czcionki ttf. Załączam zestaw gotowej do zainstalowania czytelnej czcionki z pakietu <a href="https://fedorahosted.org/liberation-fonts/">liberation-fonts</a>. Które są upowszechnione na licencji GPL.</p>
<p><a href="http://piotr.eldora.pl/weblog/wp-content/uploads/2009/01/fonttar.bz2">Pobierz</a></p>
]]></content:encoded>
			<wfw:commentRss>http://piotr.eldora.pl/2009/01/19/fpdf-polskie-wolne-czcionki/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Odmiana imion php mysql</title>
		<link>http://piotr.eldora.pl/2009/01/12/odmiana-imion-php-mysql</link>
		<comments>http://piotr.eldora.pl/2009/01/12/odmiana-imion-php-mysql#comments</comments>
		<pubDate>Mon, 12 Jan 2009 03:26:57 +0000</pubDate>
		<dc:creator>Piotr Zaniewicz</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[imiona]]></category>
		<category><![CDATA[mysql]]></category>
		<category><![CDATA[odmiona]]></category>
		<category><![CDATA[php]]></category>

		<guid isPermaLink="false">http://piotr.eldora.pl/?p=28</guid>
		<description><![CDATA[Postanowiłem udostępnić uzupełniony zbiór odmian polskich imion dla bazy MySQL.
Plik jest gotowy do importu do bazy MySQL, zawiera imiona,  odmianę, płeć oraz ilość sylab występujących w imieniu. Można go wykorzystać na przykład w skryptach php wysyłających życzenia urodzinowe lub pozdrowienia.
W przypadku braku odmiany, proszę wpisać w komentarzach to uzupełnię.
]]></description>
			<content:encoded><![CDATA[<p>Postanowiłem udostępnić uzupełniony zbiór <a href="http://piotr.eldora.pl/bazy-danych-kody-pocztowe-imiona-panstwa">odmian polskich imion</a> dla bazy MySQL.</p>
<p>Plik jest gotowy do importu do bazy MySQL, zawiera imiona,  odmianę, płeć oraz ilość sylab występujących w imieniu. Można go wykorzystać na przykład w skryptach php wysyłających życzenia urodzinowe lub pozdrowienia.</p>
<p>W przypadku braku odmiany, proszę wpisać w komentarzach to uzupełnię.</p>
]]></content:encoded>
			<wfw:commentRss>http://piotr.eldora.pl/2009/01/12/odmiana-imion-php-mysql/feed</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>Suhosin and maximum $_POST variables limit</title>
		<link>http://piotr.eldora.pl/2008/04/23/suhosin-maximum-post-variables-php-limit</link>
		<comments>http://piotr.eldora.pl/2008/04/23/suhosin-maximum-post-variables-php-limit#comments</comments>
		<pubDate>Wed, 23 Apr 2008 21:30:54 +0000</pubDate>
		<dc:creator>Piotr Zaniewicz</dc:creator>
				<category><![CDATA[Web]]></category>
		<category><![CDATA[apache]]></category>
		<category><![CDATA[max]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[post]]></category>
		<category><![CDATA[suhosin]]></category>
		<category><![CDATA[variables]]></category>

		<guid isPermaLink="false">http://piotr.eldora.pl/2008/04/23/suhosin-saved-my-day-again</guid>
		<description><![CDATA[I had a problem of more than 200 $_POST variables in one of my php scripts. Something was limiting the script not to process more than 200 in the $_POST array.
After unsuccessfully trying to find some info about how to change it in php.ini or apache.conf I found a solution using Suhosin:
You simply add the [...]]]></description>
			<content:encoded><![CDATA[<p>I had a problem of more than 200 $_POST variables in one of my php scripts. Something was limiting the script not to process more than 200 in the $_POST array.</p>
<p>After unsuccessfully trying to find some info about how to change it in php.ini or apache.conf I found a solution using Suhosin:</p>
<p>You simply add the following to your php.ini file after loading the suhosin module:</p>
<p>[suhosin]<br />
suhosin.post.max_vars = 2000<br />
suhosin.request.max_vars = 2000</p>
<p>That&#8217;s easy now <img src='http://piotr.eldora.pl/weblog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p><strong>Update: remember to restart Apache after making these changes.</strong></p>
]]></content:encoded>
			<wfw:commentRss>http://piotr.eldora.pl/2008/04/23/suhosin-maximum-post-variables-php-limit/feed</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Suhosin &#8211; customize php security</title>
		<link>http://piotr.eldora.pl/2008/04/09/suhosin-customize-php-security</link>
		<comments>http://piotr.eldora.pl/2008/04/09/suhosin-customize-php-security#comments</comments>
		<pubDate>Wed, 09 Apr 2008 19:46:37 +0000</pubDate>
		<dc:creator>Piotr Zaniewicz</dc:creator>
				<category><![CDATA[Web]]></category>

		<guid isPermaLink="false">http://piotr.eldora.pl/2008/04/09/suhosin-customize-php-security</guid>
		<description><![CDATA[I was trying to configure my virtualhosts to have different php options regarding shell access. After some research I came up with Suhosin solution, which solved problems with setting disable_functions per virtualhost. Look it up!
]]></description>
			<content:encoded><![CDATA[<p>I was trying to configure my virtualhosts to have different php options regarding shell access. After some research I came up with Suhosin solution, which solved problems with setting <em>disable_functions</em> per virtualhost. <a href="http://www.hardened-php.net/suhosin.127.html" target="_blank">Look it up</a>!</p>
]]></content:encoded>
			<wfw:commentRss>http://piotr.eldora.pl/2008/04/09/suhosin-customize-php-security/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title></title>
		<link>http://piotr.eldora.pl/2008/03/10/19</link>
		<comments>http://piotr.eldora.pl/2008/03/10/19#comments</comments>
		<pubDate>Mon, 10 Mar 2008 10:36:32 +0000</pubDate>
		<dc:creator>Piotr Zaniewicz</dc:creator>
				<category><![CDATA[General]]></category>

		<guid isPermaLink="false">http://piotr.eldora.pl/2008/03/10/19</guid>
		<description><![CDATA[&#8220;Formulate and stamp indelibly on your mind a mental picture of yourself as succeeding. Hold this picture tenaciously. Never permit it to fade. Your mind will seek to develop the picture.&#8221;
&#8211; Norman Vincent Peale, Author 
]]></description>
			<content:encoded><![CDATA[<p><span style="font-weight: bold; font-size: 12pt; color: #336699; font-family: Arial; text-decoration: none">&#8220;</span><span style="font-weight: bold; font-size: 12pt; color: #336699; font-family: Arial; text-decoration: none">Formulate and stamp indelibly on your mind a mental picture of yourself as succeeding. Hold this picture tenaciously. Never permit it to fade. Your mind will seek to develop the picture</span><span style="font-weight: bold; font-size: 12pt; color: #336699; font-family: Arial; text-decoration: none">.&#8221;</span></p>
<p><font size="4"><span style="color: #222222; font-weight: normal; font-size: 10pt; font-family: Arial">&#8211; </span></font><font size="4"><span style="color: #222222; font-weight: normal; font-size: 10pt; font-family: Arial">Norman Vincent Peale, <em>Author</em> </span></font></p>
]]></content:encoded>
			<wfw:commentRss>http://piotr.eldora.pl/2008/03/10/19/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Skiing 2008</title>
		<link>http://piotr.eldora.pl/2008/02/03/skiing-2008</link>
		<comments>http://piotr.eldora.pl/2008/02/03/skiing-2008#comments</comments>
		<pubDate>Sun, 03 Feb 2008 14:18:23 +0000</pubDate>
		<dc:creator>Piotr Zaniewicz</dc:creator>
				<category><![CDATA[General]]></category>

		<guid isPermaLink="false">http://piotr.eldora.pl/2008/02/03/skiing-2008</guid>
		<description><![CDATA[I just uploaded some fresh pictures from skiing in Hochsoelden, Tirol, Austria. Also you will find some pictures from Schwangau, Hohenschwangau and Neuschwanstein. Yes I was writing these names from memory  
Have a look, they are great.
]]></description>
			<content:encoded><![CDATA[<p>I just uploaded some fresh pictures from skiing in Hochsoelden, Tirol, Austria. Also you will find some pictures from Schwangau, Hohenschwangau and Neuschwanstein. Yes I was writing these names from memory <img src='http://piotr.eldora.pl/weblog/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </p>
<p>Have a look, they are great.</p>
]]></content:encoded>
			<wfw:commentRss>http://piotr.eldora.pl/2008/02/03/skiing-2008/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Getting the Spanish N.I.E. &#8211; social security number for foreigners</title>
		<link>http://piotr.eldora.pl/2007/10/07/getting-the-spanish-nie-social-security-number-for-foreigners</link>
		<comments>http://piotr.eldora.pl/2007/10/07/getting-the-spanish-nie-social-security-number-for-foreigners#comments</comments>
		<pubDate>Sun, 07 Oct 2007 18:21:55 +0000</pubDate>
		<dc:creator>Piotr Zaniewicz</dc:creator>
				<category><![CDATA[School]]></category>

		<guid isPermaLink="false">http://piotr.eldora.pl/2007/10/07/getting-the-spanish-nie-social-security-number-for-foreigners</guid>
		<description><![CDATA[Just recently I obtained the Numero de Identidad de Extranjero, which allows me in Spain to get a job, buy a car/house etc. Very important number if you want to live in Spain for a longer time. The number you get is valid forever, you just have to renew the certificate (every 5 years).
For European [...]]]></description>
			<content:encoded><![CDATA[<p>Just recently I obtained the Numero de Identidad de Extranjero, which allows me in Spain to get a job, buy a car/house etc. Very important number if you want to live in Spain for a longer time. The number you get is valid forever, you just have to renew the certificate (every 5 years).</p>
<p>For European Union citizens there are 2 steps involved in obtaining it. The first one is to get an appointment. You can try calling the COMISARIA GENERAL DE EXTRANJERIA to get the appointment but in my case it was easier to go to the <a href="http://maps.google.com/maps/ms?num=100&amp;hl=en&amp;client=firefox-a&amp;ie=UTF8&amp;near=Madryt,+Espa%C3%B1a&amp;fb=1&amp;li=lmd&amp;msa=0&amp;ll=40.406332,-3.707982&amp;spn=0.005956,0.014334&amp;z=17&amp;om=1&amp;msid=114848204861171584182.00043beb3b6b79dcd7d8d" title="Map" target="_blank">office</a> at 4am and wait for the registration at 9am. The good thing was that I went there with 3 friends, so we were not that bored as you can see on the pictures. Remember to bring your passport for that meeting. The officer will schedule you for an appointment that will take place after about 8 days. You will get forms needed to be filled out and a form to pay 6.70EUR for the issuance of the number.</p>
<p>Fill out the forms, pay the &#8220;tasa&#8221; at any bank, bring your passport, <strong>1 photocopy of your passport</strong> and to be on the safe side, bring 3 recent photographs of yourself (I didn&#8217;t need to give them in but&#8230;). You should obtain you N.I.E. number on the same day.</p>
]]></content:encoded>
			<wfw:commentRss>http://piotr.eldora.pl/2007/10/07/getting-the-spanish-nie-social-security-number-for-foreigners/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
