<?xml version="1.0"?>
<rss version="2.0">
  <channel>
    <title>PHPDeveloper.org</title>
    <link>http://www.phpdeveloper.org</link>
    <description>Up-to-the Minute PHP News, views and community</description>
    <language>en-us</language>
    <pubDate>Wed, 22 May 2013 18:40:52 -0500</pubDate>
    <ttl>30</ttl>
    <item>
      <title><![CDATA[Sean Coates' Blog: Arbitrary Incrementer in PHP]]></title>
      <guid>http://www.phpdeveloper.org/news/14918</guid>
      <link>http://www.phpdeveloper.org/news/14918</link>
      <description><![CDATA[<p>
In a new post to his blog <i>Sean Coates</i> <a href="http://seancoates.com/blogs/arbitrary-incrementer-in-php">shares a technique</a> he's used to pull an arbitrary incrementer from a certain set of characters.
</p>
<blockquote>
On several recent occasions I had a need for an incrementer that uses an arbitrary character set and I thought I'd share my code with you. I've used this code in the <a href="http://caedmon.net/gplvirus.phps">GPL Virus</a> that I wrote to poke fun at the <A href="http://www.google.com/search?q=wordpress+gpl+thesis">Wordpress/Thesis/GPL debacle</a>, as well as in some <a href="http://github.com/scoates/jsbin">clean up</a> I'm doing for the extremely useful <A href="http://jsbin.com/">JS Bin</a> project.
</blockquote>
<p>
He's used the technique in an upcoming URL shortening service to make the shortest possible URLs without overlap. He tried a few methods including using <a href="http://www.php.net/dechex>dechex</a> and <a href="http://www.php.net/base_convert">base_convert</a> but they had their limitations. Ultimately, he settled on a custom function that, based on a given character set and increments over it recursively.
</p>]]></description>
      <pubDate>Fri, 06 Aug 2010 12:09:28 -0500</pubDate>
    </item>
  </channel>
</rss>
