<?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>b4r7 &#187; siti</title>
	<atom:link href="http://www.valeriovendrame.it/blog/cat/siti/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.valeriovendrame.it/blog</link>
	<description>blocco note 2.0</description>
	<lastBuildDate>Mon, 08 Mar 2010 07:39:28 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=abc</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>PeerBlock (PeerGuardian is back)</title>
		<link>http://www.valeriovendrame.it/blog/peerblock-peerguardian-is-back/</link>
		<comments>http://www.valeriovendrame.it/blog/peerblock-peerguardian-is-back/#comments</comments>
		<pubDate>Mon, 08 Mar 2010 07:39:28 +0000</pubDate>
		<dc:creator>Valerio Vendrame</dc:creator>
				<category><![CDATA[siti]]></category>

		<guid isPermaLink="false">http://www.valeriovendrame.it/blog/?p=236</guid>
		<description><![CDATA[Per chi come me ha sentito la mancanza di PeerGuardian: PeerBlock ci consolerà.
PeerGuardian 2 users should check out PeerBlock, which just released  version 1.0.  It is a continuation from where PeerGuardian 2 development  left off, with many bug fixes and support for Windows Vista and Windows  7. [PhoenixLabs]
PeerBlock lets you control [...]]]></description>
			<content:encoded><![CDATA[<p>Per chi come me ha sentito la mancanza di <a href="http://phoenixlabs.org/pg2/">PeerGuardian</a>: <a href="http://www.peerblock.com/">PeerBlock</a> ci consolerà.</p>
<blockquote><p><em>PeerGuardian 2</em> users should check out <strong>PeerBlock</strong>, which just released  version 1.0.  It is a continuation from where PeerGuardian 2 development  left off, with many bug fixes and support for Windows Vista and Windows  7. [<a href="http://phoenixlabs.org/2009/09/30/peerblock-1-0-released/">PhoenixLabs</a>]</p></blockquote>
<blockquote><p><em>PeerBlock</em> lets you control who your computer "talks to" on the  Internet.  By selecting appropriate lists of "known bad" computers, you  can block communication with advertising or spyware oriented servers,  computers monitoring your p2p activities, computers which have been  "hacked", even entire countries!  They can't get in to your computer,  and your computer won't try to send them anything either.</p>
<p>And best of all, it's free! [<a href="http://www.peerblock.com/releases/public-releases/peerblock-1.0.0-r181">PeerBlock</a>]</p></blockquote>
<p>L'ultima distribuzione è raggiungibile alla pagina dei <a href="http://www.peerblock.com/releases">Downloads</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.valeriovendrame.it/blog/peerblock-peerguardian-is-back/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>convert for windows</title>
		<link>http://www.valeriovendrame.it/blog/convert-for-windows/</link>
		<comments>http://www.valeriovendrame.it/blog/convert-for-windows/#comments</comments>
		<pubDate>Fri, 18 Sep 2009 03:10:28 +0000</pubDate>
		<dc:creator>Valerio Vendrame</dc:creator>
				<category><![CDATA[cazzeggi]]></category>
		<category><![CDATA[piccì]]></category>
		<category><![CDATA[siti]]></category>
		<category><![CDATA[tips]]></category>

		<guid isPermaLink="false">http://www.valeriovendrame.it/blog/?p=193</guid>
		<description><![CDATA[Convert is a free and easy to use unit conversion program that will convert the most popular units of distance, temperature, volume, time, speed, mass, power, density, pressure, energy and many others, including the ability to create custom conversions!
Screenshot

System Requirements
Convert  will run on the following supported operating systems:

Windows 95
Windows NT 4
Windows 98
Windows 98SE
Windows ME
Windows [...]]]></description>
			<content:encoded><![CDATA[<p>Convert is a free and easy to use unit conversion program that will convert the most popular units of distance, temperature, volume, time, speed, mass, power, density, pressure, energy and many others, including the ability to create custom conversions!</p>
<h3>Screenshot</h3>
<p style="text-align: center;"><a href="http://joshmadison.com/software/convert-for-windows/"><img class="aligncenter size-full wp-image-204" title="convertAni" src="http://www.valeriovendrame.it/blog/wp-content/uploads/2009/09/convertAni.gif" alt="convertAni" width="395" height="306" /></a></p>
<h3>System Requirements</h3>
<p>Convert  will run on the following supported operating systems:</p>
<ul>
<li>Windows 95</li>
<li>Windows NT 4</li>
<li>Windows 98</li>
<li>Windows 98SE</li>
<li>Windows ME</li>
<li>Windows 2000</li>
<li>Windows XP</li>
<li>Windows 2003</li>
<li>Windows Vista</li>
<li>Windows 7</li>
<li>Anything that runs <a href="http://www.winehq.org/">Wine</a> (not officially supported) [Convert runs quite well on Linux and UNIX using <a href="http://www.winehq.org/">Wine</a>.  If you do this, you may need to change the tab layout to use a single row by going into <strong>Options &gt; Preferences &gt; Tabs</strong>, and clear the <strong>Multiple Lines</strong> option]</li>
</ul>
<p><strong>If your operating system is not listed above, Convert will not run on it.</strong></p>
<h3>Download Types</h3>
<p>There are two ways to download Convert.</p>
<ul>
<li><a href="http://joshmadison.com/software/dl/?dl=convertExe4.10">ConvertSetup.exe</a> (780kb) is a full InstallShield installation which sets up directories, icons, and supports uninstallation. This download is recommended for most users.</li>
<li><a href="http://joshmadison.com/software/dl/?dl=convertZip4.10">convert.zip</a> (153kb) is a ZIP file of just the executable. You can unZIP it with your favorite ZIP tool and just run the executable. This download is recommended for experienced users.</li>
</ul>
<h3>Other Information</h3>
<ul>
<li><a href="http://joshmadison.com/article/frequently-asked-questions">Frequently Asked Questions</a></li>
<li><a href="http://joshmadison.com/article/convert-suggestions">Suggestions</a></li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://www.valeriovendrame.it/blog/convert-for-windows/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>camel case con PHP</title>
		<link>http://www.valeriovendrame.it/blog/camel-case-con-php/</link>
		<comments>http://www.valeriovendrame.it/blog/camel-case-con-php/#comments</comments>
		<pubDate>Mon, 10 Aug 2009 18:48:40 +0000</pubDate>
		<dc:creator>Valerio Vendrame</dc:creator>
				<category><![CDATA[piccì]]></category>
		<category><![CDATA[siti]]></category>
		<category><![CDATA[tips]]></category>

		<guid isPermaLink="false">http://www.valeriovendrame.it/blog/?p=183</guid>
		<description><![CDATA[&#60;?php
$testo = "qualCOSA che vuOI mettere in Camel CASE";
echo ucwords(strtolower($testo)); //Qualcosa Che Vuoi Mettere In Camel Case
?&#62;
strtolower: http://it.php.net/manual/en/function.strtolower.php
ucwords: http://it.php.net/manual/en/function.ucwords.php
]]></description>
			<content:encoded><![CDATA[<pre>&lt;?php
$testo = "qualCOSA che vuOI mettere in Camel CASE";
echo <span style="color: red;">ucwords(strtolower($testo))</span>; //Qualcosa Che Vuoi Mettere In Camel Case
?&gt;</pre>
<p>strtolower: <a title="strtolower - php.net" href="http://it.php.net/manual/en/function.strtolower.php">http://it.php.net/manual/en/function.strtolower.php</a><br />
ucwords: <a title="uwords - php.net" href="http://it.php.net/manual/en/function.ucwords.php">http://it.php.net/manual/en/function.ucwords.php</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.valeriovendrame.it/blog/camel-case-con-php/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>moccia e camilleri no!</title>
		<link>http://www.valeriovendrame.it/blog/moccia-e-camilleri-no/</link>
		<comments>http://www.valeriovendrame.it/blog/moccia-e-camilleri-no/#comments</comments>
		<pubDate>Mon, 06 Jul 2009 10:57:01 +0000</pubDate>
		<dc:creator>Valerio Vendrame</dc:creator>
				<category><![CDATA[siti]]></category>

		<guid isPermaLink="false">http://www.valeriovendrame.it/blog/?p=172</guid>
		<description><![CDATA[moccia assieme a camilleri, in sconto, NO!
]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.scrnshots.com/users/lelebart/screenshots/178822">moccia assieme a camilleri</a>, <a href="http://clientsection.contactlab.it/service/display/index.php?d=Zz0yMDAwNDc1JnE9ODcxMjg4NiZlPUxFTEVCQVJUQFlBSE9PLklU%0A">in sconto</a>, NO!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.valeriovendrame.it/blog/moccia-e-camilleri-no/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>spider-bot</title>
		<link>http://www.valeriovendrame.it/blog/spider-bot/</link>
		<comments>http://www.valeriovendrame.it/blog/spider-bot/#comments</comments>
		<pubDate>Tue, 16 Jun 2009 10:23:31 +0000</pubDate>
		<dc:creator>Valerio Vendrame</dc:creator>
				<category><![CDATA[siti]]></category>

		<guid isPermaLink="false">http://www.valeriovendrame.it/blog/?p=157</guid>
		<description><![CDATA[versi in libert&#224; animaleschi tipici di un pseudo-nerd-suino-di-spritz-letterario:
spider-bot, spider-bot
il sito tu mi tocch'
tu mi navighi nel forum
e m'indicizzi tutto d'oro
tu quaaa.. ti amo spider-bot
]]></description>
			<content:encoded><![CDATA[<p>versi in libert&agrave; animaleschi tipici di un pseudo-nerd-suino-di-<a title="Spritz Letterario" href="http://spritzletterario.splinder.com/">spritz-letterario</a>:</p>
<blockquote><p>spider-bot, spider-bot<br />
il sito tu mi tocch'<br />
tu mi navighi nel forum<br />
e m'indicizzi tutto d'oro<br />
tu quaaa.. ti amo spider-bot</p></blockquote>
]]></content:encoded>
			<wfw:commentRss>http://www.valeriovendrame.it/blog/spider-bot/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>jquery font resizer</title>
		<link>http://www.valeriovendrame.it/blog/jquery-font-resizer/</link>
		<comments>http://www.valeriovendrame.it/blog/jquery-font-resizer/#comments</comments>
		<pubDate>Mon, 11 May 2009 23:01:20 +0000</pubDate>
		<dc:creator>Valerio Vendrame</dc:creator>
				<category><![CDATA[siti]]></category>

		<guid isPermaLink="false">http://www.valeriovendrame.it/blog/?p=151</guid>
		<description><![CDATA[via: http://devolux.org/2009/03/jquery-font-resizer/
I just programmed a simple but nicely working jQuery font resizer. I intend to create a jQuery and a Wordpress plug-in from it.




Required are the jQeruy core and the jQuery plug-in "COOKIE". Here you see the font resizer jQuery code:

$(document).ready(function(){

$("#small").click(function(event){
event.preventDefault();
$("#page").css("font-size","8px");
$.cookie("fontSize","8px");
});

$("#default").click(function(event){
event.preventDefault();
$("#page").css("font-size","10px");
$.cookie("fontSize","10px");
});

$("#large").click(function(event){
event.preventDefault();
$("#page").css("font-size","12px");
$.cookie("fontSize","12px");
});

// Cookie
var fontSize = $.cookie("fontSize");

// Calling Cookie
if(fontSize == "8px") {
$("#page").css("font-size","8px");
};

if(fontSize == "10px") {
$("#page").css("font-size","10px");
};

if(fontSize == "12px") [...]]]></description>
			<content:encoded><![CDATA[<p>via: <a href="http://devolux.org/2009/03/jquery-font-resizer/">http://devolux.org/2009/03/jquery-font-resizer/</a></p>
<blockquote><p>I just programmed a simple but nicely working jQuery font resizer. I intend to create a jQuery and a Wordpress plug-in from it.</p>
<div class="post_right">
<img src="http://devolux.org/wp-content/uploads/2009/03/jquery-logo.png" alt="jquery-logo" title="jquery-logo"/>
</div>
<div class="single_content">
<p>Required are the jQeruy core and the jQuery plug-in "COOKIE". Here you see the font resizer jQuery code:</p>
<pre name="code" class="js">
$(document).ready(function(){

$("#small").click(function(event){
event.preventDefault();
$("#page").css("font-size","8px");
$.cookie("fontSize","8px");
});

$("#default").click(function(event){
event.preventDefault();
$("#page").css("font-size","10px");
$.cookie("fontSize","10px");
});

$("#large").click(function(event){
event.preventDefault();
$("#page").css("font-size","12px");
$.cookie("fontSize","12px");
});

// Cookie
var fontSize = $.cookie("fontSize");

// Calling Cookie
if(fontSize == "8px") {
$("#page").css("font-size","8px");
};

if(fontSize == "10px") {
$("#page").css("font-size","10px");
};

if(fontSize == "12px") {
$("#page").css("font-size","12px");
};

});
</pre>
<p>In addition, the font resizer affects two other files of your website. You must insert three links into your html document, just as it is done here:</p>
<pre name="code" class="html">
&lt;html&gt;
&lt;head&gt;

&lt;title&gt;font resizer&lt;/title&gt;
&lt;link rel="stylesheet" href="fontResizer.css" type="text/css" /&gt;
&lt;script type="text/javascript" src="jquery-1-3-2.js"&gt;&lt;/script&gt;
&lt;script type="text/javascript" src="cookies.js"&gt;&lt;/script&gt;
&lt;script type="text/javascript" src="fontResizer.js"&gt;&lt;/script&gt;
&lt;/head&gt;

&lt;body&gt;
&lt;div id="page"&gt;
&lt;p&gt;
&lt;a id="small" href="http://jquery.com/"&gt;small&lt;/a&gt;
&lt;a id="default" href="http://jquery.com/"&gt;default&lt;/a&gt;
&lt;a id="large" href="http://jquery.com/"&gt;large&lt;/a&gt;

&lt;/p&gt;

&lt;div id="content"&gt;
Lorem ipsum dolor sit amet, consetetur sadipscing elitr,&nbsp; sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet. Lorem ipsum dolor sit amet, consetetur sadipscing elitr,&nbsp; sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet. Lorem ipsum dolor sit amet, consetetur sadipscing elitr,&nbsp; sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet.
Duis autem vel eum iriure dolor in hendrerit in vulputate velit esse molestie consequat, vel illum dolore eu feugiat nulla facilisis at vero eros et accumsan et iusto odio dignissim qui blandit praesent luptatum zzril delenit augue duis dolore te feugait nulla facilisi. Lorem ipsum dolor sit amet, consectetuer adipiscing elit, sed diam nonummy nibh euismod tincidunt ut laoreet dolore magna aliquam erat volutpat.
Ut wisi enim ad minim veniam, quis nostrud exerci tation ullamcorper suscipit lobortis nisl ut aliquip ex ea commodo consequat. Duis autem vel eum iriure dolor in hendrerit in vulputate velit esse molestie consequat, vel illum dolore eu feugiat nulla facilisis at vero eros et accumsan et iusto odio dignissim qui blandit praesent luptatum zzril delenit augue duis dolore te feugait nulla facilisi.
Nam liber tempor cum soluta nobis eleifend option congue nihil imperdiet doming id quod mazim placerat facer possim assum. Lorem ipsum dolor sit amet, consectetuer adipiscing elit, sed diam nonummy nibh euismod tincidunt ut laoreet dolore magna aliquam erat volutpat. Ut wisi enim ad minim veniam, quis nostrud exerci tation ullamcorper suscipit lobortis nisl ut aliquip ex ea commodo consequat.
&lt;p id="test"&gt;Duis autem vel eum iriure dolor in hendrerit&lt;/p&gt; in vulputate velit esse molestie consequat, vel illum dolore eu feugiat nulla facilisis.
At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet. Lorem ipsum dolor sit amet, consetetur sadipscing elitr,&nbsp; sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet. Lorem ipsum dolor sit amet, consetetur sadipscing elitr,&nbsp; At accusam aliquyam diam diam dolore dolores duo eirmod eos erat, et nonumy sed tempor et et invidunt justo labore Stet clita ea et gubergren, kasd magna no rebum. sanctus sea sed takimata ut vero voluptua. est Lorem ipsum dolor sit amet. Lorem ipsum dolor sit amet, consetetur sadipscing elitr,&nbsp; sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat.
Consetetur sadipscing elitr,&nbsp; sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet. Lorem ipsum dolor sit amet, consetetur sadipscing elitr,&nbsp; sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet. Lorem ipsum dolor sit amet, consetetur sadipscing elitr,&nbsp; sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet.

&lt;/div&gt;
&lt;/div&gt;
&lt;/body&gt;
&lt;/html&gt;
</pre>
<p>Finally it is essential that only the outward element of your document owns an absolute CSS font size. All elements inside it must obtain <em>relative</em> font sizes. These will be in relation to the value set in the outward container. Have a look at the following CSS:</p>
<pre name="code" class="css">
div#page
{font: normal 10px Verdana;}

a
{font-size: 110%;}

div#content
{font-size: 120%;}
</pre>
<p>This will result in an 11px font size for all a-element and a12px font size for divs. That&#39;s it. I hope you will enjoy it.</p>
<p><strong>Note: </strong>If you should use this code on your homepage I&#39;d be very graceful for creating also a link to my website.</p>
</div>
</blockquote>
<p>e adesso si ragiona per integrarlo bene a PHP-Fusion..</p>
]]></content:encoded>
			<wfw:commentRss>http://www.valeriovendrame.it/blog/jquery-font-resizer/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>come risolvere: &#8220;_gat is not defined&#8221;</title>
		<link>http://www.valeriovendrame.it/blog/come-risolvere-_gat-is-not-defined/</link>
		<comments>http://www.valeriovendrame.it/blog/come-risolvere-_gat-is-not-defined/#comments</comments>
		<pubDate>Wed, 06 May 2009 03:04:05 +0000</pubDate>
		<dc:creator>Valerio Vendrame</dc:creator>
				<category><![CDATA[siti]]></category>

		<guid isPermaLink="false">http://www.valeriovendrame.it/blog/?p=148</guid>
		<description><![CDATA[via: http://vpxcc.wordpress.com/
Just a small JavaScript addition can solve a minor bug in Google's Analytics Script. If anybody has a common AdBlocker installed and visits your Google Analytics enhanced page, she will notice 2 errors, including the famous: "_gat is not defined". Looks like the google script does not validate if the actual tracking script is [...]]]></description>
			<content:encoded><![CDATA[<p>via: <a href="http://vpxcc.wordpress.com/2008/06/06/howto-solve-_gat-is-not-defined-a-google-analytics-workaround/">http://vpxcc.wordpress.com/</a></p>
<blockquote><p>Just a small JavaScript addition can solve a minor bug in Google's Analytics Script. If anybody has a common AdBlocker installed and visits your Google Analytics enhanced page, she will notice 2 errors, including the famous: "_gat is not defined". Looks like the google script does not validate if the actual tracking script is already loaded before it is executed.</p>
<p>As a quick work around add the following BOLD lines around your script:</p>
<pre>&lt;script type="text/javascript"&gt;
<strong>if (typeof(_gat) == 'object') { </strong>
    var pageTracker (YOUR TRACKING CODE)
    ...
<strong>}</strong>
&lt;/script&gt;</pre>
<p>ét voilá.</p></blockquote>
]]></content:encoded>
			<wfw:commentRss>http://www.valeriovendrame.it/blog/come-risolvere-_gat-is-not-defined/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>slug_me</title>
		<link>http://www.valeriovendrame.it/blog/slug_me/</link>
		<comments>http://www.valeriovendrame.it/blog/slug_me/#comments</comments>
		<pubDate>Wed, 29 Apr 2009 23:36:17 +0000</pubDate>
		<dc:creator>Valerio Vendrame</dc:creator>
				<category><![CDATA[meditazioni]]></category>
		<category><![CDATA[piccì]]></category>
		<category><![CDATA[siti]]></category>

		<guid isPermaLink="false">http://www.valeriovendrame.it/blog/?p=133</guid>
		<description><![CDATA[a better (?) version of toAscii function by Matteo Spinelli
function slug_me($str, $replace=array(), $delimiter='-', $charset='ISO-8859-1') {
	$str = iconv($charset, 'UTF-8', $str);
	if (!empty($replace)) { $str = str_replace((array)$replace, ' ', $str); }
	$clean = iconv('UTF-8', 'ASCII//TRANSLIT', $str);
	$clean = preg_replace("/[^a-zA-Z0-9\/_&#124;+ -]/", '', $clean);
	$clean = strtolower(trim($clean, '-'));
	$clean = preg_replace("/[\/_&#124;+ -]+/", $delimiter, $clean);
	return $clean;
}
]]></description>
			<content:encoded><![CDATA[<p>a better (?) version of <a href="http://cubiq.org/the-perfect-php-clean-url-generator/12"><strong>toAscii</strong> function by Matteo Spinelli</a></p>
<pre>function slug_me($str, $replace=array(), $delimiter='-', $charset='ISO-8859-1') {
	$str = iconv($charset, 'UTF-8', $str);
	if (!empty($replace)) { $str = str_replace((array)$replace, ' ', $str); }
	$clean = iconv('UTF-8', 'ASCII//TRANSLIT', $str);
	$clean = preg_replace("/[^a-zA-Z0-9\/_|+ -]/", '', $clean);
	$clean = strtolower(trim($clean, '-'));
	$clean = preg_replace("/[\/_|+ -]+/", $delimiter, $clean);
	return $clean;
}</pre>
]]></content:encoded>
			<wfw:commentRss>http://www.valeriovendrame.it/blog/slug_me/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>The perfect PHP clean url generator</title>
		<link>http://www.valeriovendrame.it/blog/the-perfect-php-clean-url-generator/</link>
		<comments>http://www.valeriovendrame.it/blog/the-perfect-php-clean-url-generator/#comments</comments>
		<pubDate>Sun, 26 Apr 2009 22:12:40 +0000</pubDate>
		<dc:creator>Valerio Vendrame</dc:creator>
				<category><![CDATA[han detto]]></category>
		<category><![CDATA[piccì]]></category>
		<category><![CDATA[siti]]></category>
		<category><![CDATA[tips]]></category>

		<guid isPermaLink="false">http://www.valeriovendrame.it/blog/?p=122</guid>
		<description><![CDATA[via: http://cubiq.org/the-perfect-php-clean-url-generator/12
In my hunt for the perfect clean url (smart url, slug, permalink, whatever) generator I've always slipped in some exception or bug that made the function a piece of junk. But I recently found an easy solution I hope I could call "definitive".
Clean url generators are crucial for search engine optimization or just to [...]]]></description>
			<content:encoded><![CDATA[<p>via: <a href="http://cubiq.org/the-perfect-php-clean-url-generator/12">http://cubiq.org/the-perfect-php-clean-url-generator/12</a></p>
<blockquote><p>In my hunt for the perfect clean url (smart url, slug, permalink, whatever) generator I've always slipped in some exception or bug that made the function a piece of junk. But I recently found an easy solution I hope I could call "definitive".</p>
<p>Clean url generators are crucial for search engine optimization or just to tidy up the site navigation. They are even more important if you work with international characters, accented vowels <code>/à, è, ì, .../</code>, cedilla <code>/ç/</code>, dieresis <code>/ë/</code>, tilde <code>/ñ/</code> and so on.</p>
<p>First of all we need to strip all special characters and punctuation away. This is easily accomplished with something like:</p>
<pre>function toAscii($str) {
	$clean = preg_replace("/[^a-zA-Z0-9\/_|+ -]/", '', $str);
	$clean = strtolower(trim($clean, '-'));
	$clean = preg_replace("/[\/_|+ -]+/", '-', $clean);

	return $clean;
}</pre>
<p>With our <code>toAscii</code> function we can convert a string like <em>“Hi! I’m the title of your page!”</em> to <code>hi-im-the-title-of-your-page</code>. This is nice, but what happens with a title like <em>“A piñata is a paper container filled with candy”</em>?<br />
The result will be <code>a-piata-is-a-paper-container-filled-with-candy</code>, which is not cool. We need to convert all special characters to the closest ascii character equivalent.</p>
<p>There are many ways to do this, maybe the easiest is by using <a href="http://www.php.net/iconv">iconv</a>.</p>
<pre>setlocale(LC_ALL, 'en_US.UTF8');
function toAscii($str) {
	$clean = iconv('UTF-8', 'ASCII//TRANSLIT', $str);
	$clean = preg_replace("/[^a-zA-Z0-9\/_| -]/", '', $clean);
	$clean = strtolower(trim($clean, '-'));
	$clean = preg_replace("/[\/_| -]+/", '-', $clean);

	return $clean;
}</pre>
<p>I always work with UTF-8 but you can obviously use any character encoding recognized by your system. The <em>piñata</em> text is now transliterated into <code>a-pinata-is-a-paper-container-filled-with-candy</code>. Lovable.<br />
If they are not Spanish, users will hardly search your site for the word <em>piñata</em>, they will most likely search for <em>pinata</em>. So you may want to store both versions in your database. You may have a <em>title</em> field with the actual displayed text and a <em>slug</em> field containing its ascii version counterpart.</p>
<p>We can add a delimiter parameter to our function so we can use it to generate both clean urls and slugs (in newspaper editing, a slug is a short name given to an article that is in production, <a tooltip="linkalert-tip" href="http://en.wikipedia.org/wiki/Slug_%28production%29">source</a>).</p>
<pre>setlocale(LC_ALL, 'en_US.UTF8');
function toAscii($str, $delimiter='-') {
	$clean = iconv('UTF-8', 'ASCII//TRANSLIT', $str);
	$clean = preg_replace("/[^a-zA-Z0-9\/_|+ -]/", '', $clean);
	$clean = strtolower(trim($clean, '-'));
	$clean = preg_replace("/[\/_|+ -]+/", $delimiter, $clean);

	return $clean;
}

// echo toAscii("A piñata is a paper container filled with candy.", ' ');
// returns: a pinata is a paper container filled with candy
</pre>
<p>There’s one more thing. The string <em>“I’ll be back!”</em> is converted to <code>ill-be-back</code>. This may or may not be an issue depending on your application. If you use the function to generate a searchable slug for example, looking for “ill” would return the famous Terminator quote that probably isn’t what you wanted.</p>
<pre>setlocale(LC_ALL, 'en_US.UTF8');
function toAscii($str, $replace=array(), $delimiter='-') {
	if( !empty($replace) ) {
		$str = str_replace((array)$replace, ' ', $str);
	}

	$clean = iconv('UTF-8', 'ASCII//TRANSLIT', $str);
	$clean = preg_replace("/[^a-zA-Z0-9\/_|+ -]/", '', $clean);
	$clean = strtolower(trim($clean, '-'));
	$clean = preg_replace("/[\/_|+ -]+/", $delimiter, $clean);

	return $clean;
}</pre>
<p>You can now pass custom delimiters to the function. Calling <code>toAscii("I'll be back!", "'")</code> you’ll get <code>i-ll-be-back</code>. Also note that the apostrophe is replaced before the string is converted to ascii as character encoding conversion may lead to weird results, for example <code>é</code> is converted to <code>'e</code>, so the apostrophe needs to be parsed before the string is mangled by iconv.</p>
<p>The function seems now complete. Lets stress test it.</p>
<pre>echo toAscii("Mess'd up --text-- just (to) stress /test/ ?our! `little` \\clean\\ url fun.ction!?--&gt;");
returns: messd-up-text-just-to-stress-test-our-little-clean-url-function

echo toAscii("Perché l'erba è verde?", "'"); // Italian
returns: perche-l-erba-e-verde

echo toAscii("Peux-tu m'aider s'il te plaît?", "'"); // French
returns: peux-tu-m-aider-s-il-te-plait

echo toAscii("Tänk efter nu – förr'n vi föser dig bort"); // Swedish
returns: tank-efter-nu-forrn-vi-foser-dig-bort

echo toAscii("ÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏÐÑÒÓÔÕÖÙÚÛÜÝßàáâãäåæçèéêëìíîïðñòóôõöùúûüýÿ");
returns: aaaaaaaeceeeeiiiidnooooouuuuyssaaaaaaaeceeeeiiiidnooooouuuuyy

echo toAscii("Custom`delimiter*example", array('*', '`'));
returns: custom-delimiter-example

echo toAscii("My+Last_Crazy|delimiter/example", '', ' ');
returns: my last crazy delimiter example
</pre>
<p>I’m sure we are far from perfection and probably some php/regex guru will soon bury me under my ignorance suggesting an über-simple alternative to my function. What do you thing?</p></blockquote>
]]></content:encoded>
			<wfw:commentRss>http://www.valeriovendrame.it/blog/the-perfect-php-clean-url-generator/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>w3c validators</title>
		<link>http://www.valeriovendrame.it/blog/w3c-validators/</link>
		<comments>http://www.valeriovendrame.it/blog/w3c-validators/#comments</comments>
		<pubDate>Fri, 03 Apr 2009 13:05:04 +0000</pubDate>
		<dc:creator>Valerio Vendrame</dc:creator>
				<category><![CDATA[piccì]]></category>
		<category><![CDATA[siti]]></category>
		<category><![CDATA[tips]]></category>

		<guid isPermaLink="false">http://www.valeriovendrame.it/blog/?p=118</guid>
		<description><![CDATA[Leggendo l&#39;ormai famoso articolo di Robin Good (e anche per esperienza diretta) ho scoperto che rendere un sito accessibile sul web pu&#242; essere davvero una sfida estenuante, ma grazie agli strumenti che tra un attimo t&#39; illustrer&#242;, il tuo sito avr&#224; sicuramente quella marcia in pi&#249; che pu&#242; fare la differenza! 
Devi sapere che le [...]]]></description>
			<content:encoded><![CDATA[<blockquote><p>Leggendo l&#39;ormai famoso <a rel="nofollow" target="_blank" href="http://www.masternewmedia.org/it/2008/11/27/testare_la_compatibilita_di_un_sito_sui.htm">articolo di <b>Robin Good</b></a> (e anche per esperienza diretta) ho scoperto che rendere un <b>sito accessibile</b> sul web pu&ograve; essere davvero una sfida estenuante, ma grazie agli strumenti che tra un attimo t&#39; illustrer&ograve;, il tuo sito avr&agrave; sicuramente quella marcia in pi&ugrave; che pu&ograve; fare la differenza! <br />
Devi sapere che le tecnologie utilizzate per creare i siti web, cosi come i <a rel="nofollow" target="_blank" href="http://it.wikipedia.org/wiki/TCP/IP"><span style="font-family: Verdana;"><b>protocolli internet</b></span></a>sono definiti da alcuni standard ai quali bisogna attenersi per assicurarsi di avere un sito (dal punto di vista del codice) in regola. </p>
<p>Sono certo che ti starai chiedendo <b>chi crea questi standard e come fare per attenersi ad essi</b>... bene devi sapere che questi standard sono creati dal <a rel="nofollow" target="_blank" href="http://www.w3.org/"><span style="font-family: Verdana;"><b>W3C</b></span></a> (Word Wide Web Consortium) il W3C &egrave; un consorzio internazionale senza fini di lucro, che ha il compito di definire gli standard condivisi per il funzionamento e la gestione del web.<br />
Vediamo quindi come sfruttare gli <b>strumenti offerti da W3C</b> per assicurarti di avere un <b>codice conforme agli standard</b>!</p>
<p><span id="more-83"></span></p>
<p><b>Per le tue pagine che contengono marcatori HTML, XHTML, SMIL, MathML, etc </b> puoi utilizzare il <a rel="nofollow" target="_blank" href="http://validator.w3.org/"><span style="font-size: small;"><b>validatore di marcatori </b></span></a>  </p>
<p><img alt="w3c" src="http://www.squirob.com/wp-content/uploads/w3c_html_val(1).png" title="w3c" class="aligncenter" width="500"  /><br />
Come puoi vedere &egrave; semplicissimo da usare! Basta inserire l&#39;indirizzo del tuo sito e cliccare sul pulsante <b>Check </b> oppure puoi scegliere di inviare un file da analizzare nel caso il tuo sito non sia online cliccando sulla tab <b>Validate by File Upload</b>, o ancora puoi inserire direttamente il codice da analizzare cliccando sulla tab <b>Validate by Direct Input</b>.</p>
<p>Un altro strumento utilissimo che W3C ti mette a disposizione &egrave; il  <a rel="nofollow" target="_blank" href="http://validator.w3.org/checklink"> <b>Link Checker</b></a> che verifica la validit&agrave; di tutti i link presenti all&#39;indirizzo immesso!<br />
Per i tuoi <b><a rel="nofollow" target="_blank" href="http://it.wikipedia.org/wiki/Really_simple_syndication">RSS feed</a></b> invece w3c ti mette a disposizione il  <a rel="nofollow" target="_blank" href="http://validator.w3.org/feed/"><span style="font-size: small;"><b>Feed Validator</b></span></a>; anche in questo caso ti baster&agrave; inserire il link dei tuoi feed e cliccare sul pulsante Check.<br />
Per i tuoi <a rel="nofollow" target="_blank" href="http://it.wikipedia.org/wiki/Foglio_di_stile"><b>fogli di stile CSS</b></a> invece puoi utilizzare il <a rel="nofollow" target="_blank" href="http://jigsaw.w3.org/css-validator/"><span style="font-size: small;"><b>CSS Validator</b></span></a> sempre con la stessa facilit&agrave; d&#39;utilizzo degli altri strumenti</p>
<p>Non poteva mancare poi uno strumento per la convalida dei tuoi file  <a rel="nofollow" target="_blank" href="http://it.wikipedia.org/wiki/XML">XML</a> ecco quindi che w3c mette a tua disposizione l&#39;<a rel="nofollow" target="_blank" href="http://www.w3.org/2001/03/webdata/xsv"><b>XML Schema Validator</b></a> questo validator ti mette a disposizione due modalit&agrave; di utilizzo: link o file.</p>
<p>Ognuno degli strumenti che ti ho illustrato ti fornir&agrave; un dettagliato report sui problemi rilevati e alcune indicazioni per risolverli, e tutto questo a costo 0!</p>
</blockquote>
<p>via <a href="http://www.squirob.com/software-web-based/web-incrementa-laccessibilita-del-tuo-sito-a-costo-0.html">http://www.squirob.com</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.valeriovendrame.it/blog/w3c-validators/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
