<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	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/"
		>
<channel>
	<title>Comments on: PHP Unique Hash</title>
	<atom:link href="http://blog.kevburnsjr.com/php-unique-hash/feed" rel="self" type="application/rss+xml" />
	<link>http://blog.kevburnsjr.com/php-unique-hash</link>
	<description>Web Application Engineer</description>
	<lastBuildDate>Sun, 18 Dec 2011 02:08:36 -0800</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: Alec Gorge</title>
		<link>http://blog.kevburnsjr.com/php-unique-hash/comment-page-1#comment-2778</link>
		<dc:creator>Alec Gorge</dc:creator>
		<pubDate>Mon, 19 Sep 2011 21:54:16 +0000</pubDate>
		<guid isPermaLink="false">http://blog.kevburnsjr.com/?p=482#comment-2778</guid>
		<description>Kevin,

Great algorithm! I wanted to use it in my upcoming Node.js project, so I made a CommonJS/Node.js module available here: https://github.com/alecgorge/node-psuedohash

Thanks again for putting this together!</description>
		<content:encoded><![CDATA[<p>Kevin,</p>
<p>Great algorithm! I wanted to use it in my upcoming Node.js project, so I made a CommonJS/Node.js module available here: <a href="https://github.com/alecgorge/node-psuedohash" rel="nofollow">https://github.com/alecgorge/node-psuedohash</a></p>
<p>Thanks again for putting this together!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: KevBurnsJr</title>
		<link>http://blog.kevburnsjr.com/php-unique-hash/comment-page-1#comment-2752</link>
		<dc:creator>KevBurnsJr</dc:creator>
		<pubDate>Sat, 07 May 2011 06:30:26 +0000</pubDate>
		<guid isPermaLink="false">http://blog.kevburnsjr.com/?p=482#comment-2752</guid>
		<description>Using time() would probably not be a good idea, just because there&#039;s a good chance that two records may be created within the same second.

What I usually do instead for keys is 

echo time().&#039;-&#039;.base_convert(rand(1,getrandmax()), 10, 36);

which yields a key like 1304134276-udxxi7</description>
		<content:encoded><![CDATA[<p>Using time() would probably not be a good idea, just because there&#8217;s a good chance that two records may be created within the same second.</p>
<p>What I usually do instead for keys is </p>
<p>echo time().&#8217;-&#8217;.base_convert(rand(1,getrandmax()), 10, 36);</p>
<p>which yields a key like 1304134276-udxxi7</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Jenny</title>
		<link>http://blog.kevburnsjr.com/php-unique-hash/comment-page-1#comment-2751</link>
		<dc:creator>Jenny</dc:creator>
		<pubDate>Fri, 06 May 2011 14:52:45 +0000</pubDate>
		<guid isPermaLink="false">http://blog.kevburnsjr.com/?p=482#comment-2751</guid>
		<description>Me again :)
I wanted to know if you think it would be safe to run this command instead of your look.

echo PseudoCrypt::udihash(time());

I&#039;m trying to create unique HASH to be inserted as KEY on database, but generating your way the hash always stays the same.

Please let me know if there is any draw back to this solution.

Thank you!

Jenny</description>
		<content:encoded><![CDATA[<p>Me again :)<br />
I wanted to know if you think it would be safe to run this command instead of your look.</p>
<p>echo PseudoCrypt::udihash(time());</p>
<p>I&#8217;m trying to create unique HASH to be inserted as KEY on database, but generating your way the hash always stays the same.</p>
<p>Please let me know if there is any draw back to this solution.</p>
<p>Thank you!</p>
<p>Jenny</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Jenny</title>
		<link>http://blog.kevburnsjr.com/php-unique-hash/comment-page-1#comment-2750</link>
		<dc:creator>Jenny</dc:creator>
		<pubDate>Fri, 06 May 2011 14:10:35 +0000</pubDate>
		<guid isPermaLink="false">http://blog.kevburnsjr.com/?p=482#comment-2750</guid>
		<description>How many total &quot;unique&quot; possibilities are we talking about here?</description>
		<content:encoded><![CDATA[<p>How many total &#8220;unique&#8221; possibilities are we talking about here?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: John</title>
		<link>http://blog.kevburnsjr.com/php-unique-hash/comment-page-1#comment-2635</link>
		<dc:creator>John</dc:creator>
		<pubDate>Tue, 29 Mar 2011 02:49:10 +0000</pubDate>
		<guid isPermaLink="false">http://blog.kevburnsjr.com/?p=482#comment-2635</guid>
		<description>Hi, I implemented this in Factor, if you&#039;re curious:

http://re-factor.blogspot.com/2011/03/unique-hash.html</description>
		<content:encoded><![CDATA[<p>Hi, I implemented this in Factor, if you&#8217;re curious:</p>
<p><a href="http://re-factor.blogspot.com/2011/03/unique-hash.html" rel="nofollow">http://re-factor.blogspot.com/2011/03/unique-hash.html</a></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: KevBurnsJr</title>
		<link>http://blog.kevburnsjr.com/php-unique-hash/comment-page-1#comment-2630</link>
		<dc:creator>KevBurnsJr</dc:creator>
		<pubDate>Mon, 28 Mar 2011 10:28:37 +0000</pubDate>
		<guid isPermaLink="false">http://blog.kevburnsjr.com/?p=482#comment-2630</guid>
		<description>10 is probably too large.  I suggest you run it w/ 5 or 6 and append some random data.

$hash = PseudoCrypt::udihash($id, 5);
$rand = PseudoCrypt::base62(rand(0,pow(62,5)));
$rand = str_pad($rand, 5, &quot;0&quot;, STR_PAD_LEFT);
$key = $hash.$rand;</description>
		<content:encoded><![CDATA[<p>10 is probably too large.  I suggest you run it w/ 5 or 6 and append some random data.</p>
<p>$hash = PseudoCrypt::udihash($id, 5);<br />
$rand = PseudoCrypt::base62(rand(0,pow(62,5)));<br />
$rand = str_pad($rand, 5, &#8220;0&#8243;, STR_PAD_LEFT);<br />
$key = $hash.$rand;</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Druczki Pocztowe</title>
		<link>http://blog.kevburnsjr.com/php-unique-hash/comment-page-1#comment-2629</link>
		<dc:creator>Druczki Pocztowe</dc:creator>
		<pubDate>Mon, 28 Mar 2011 10:19:22 +0000</pubDate>
		<guid isPermaLink="false">http://blog.kevburnsjr.com/?p=482#comment-2629</guid>
		<description>Try rining the script with: PseudoCrypt::udihash($id, 10)

All keys wil have values:
000000000000
000000000000
000000000000
000000000000
000000000000
000000000000
000000000000
000000000000
000000000000
000000000000

How to solve it?</description>
		<content:encoded><![CDATA[<p>Try rining the script with: PseudoCrypt::udihash($id, 10)</p>
<p>All keys wil have values:<br />
000000000000<br />
000000000000<br />
000000000000<br />
000000000000<br />
000000000000<br />
000000000000<br />
000000000000<br />
000000000000<br />
000000000000<br />
000000000000</p>
<p>How to solve it?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Warren Wilkinson</title>
		<link>http://blog.kevburnsjr.com/php-unique-hash/comment-page-1#comment-2582</link>
		<dc:creator>Warren Wilkinson</dc:creator>
		<pubDate>Fri, 18 Mar 2011 04:31:46 +0000</pubDate>
		<guid isPermaLink="false">http://blog.kevburnsjr.com/?p=482#comment-2582</guid>
		<description>Hey German, if you want decodable ones --- would printing random numbers in base 64 work?   Most languages let you print in base 16 (hex) and usually (with some sleuthing) have ways to read/write base 64.</description>
		<content:encoded><![CDATA[<p>Hey German, if you want decodable ones &#8212; would printing random numbers in base 64 work?   Most languages let you print in base 16 (hex) and usually (with some sleuthing) have ways to read/write base 64.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Morteza</title>
		<link>http://blog.kevburnsjr.com/php-unique-hash/comment-page-1#comment-2412</link>
		<dc:creator>Morteza</dc:creator>
		<pubDate>Tue, 06 Jul 2010 17:40:46 +0000</pubDate>
		<guid isPermaLink="false">http://blog.kevburnsjr.com/?p=482#comment-2412</guid>
		<description>Hey, that&#039;s very useful!! I wanted to use unique IDs to generate a code as password for my users so they can come back later on the site, and enter this code, so they can edit what they entered. your algorithm is useful in my case.

thank you.

@Tim: I think, not needing the inverse function, it is not important to have different values for one number.</description>
		<content:encoded><![CDATA[<p>Hey, that&#8217;s very useful!! I wanted to use unique IDs to generate a code as password for my users so they can come back later on the site, and enter this code, so they can edit what they entered. your algorithm is useful in my case.</p>
<p>thank you.</p>
<p>@Tim: I think, not needing the inverse function, it is not important to have different values for one number.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Tim</title>
		<link>http://blog.kevburnsjr.com/php-unique-hash/comment-page-1#comment-2243</link>
		<dc:creator>Tim</dc:creator>
		<pubDate>Thu, 01 Apr 2010 21:30:20 +0000</pubDate>
		<guid isPermaLink="false">http://blog.kevburnsjr.com/?p=482#comment-2243</guid>
		<description>Wonderful function -- but the output diverges above 58 on two systems I&#039;m testing on.  I suspect it&#039;s because one&#039;s a 32bit machine, and the other 64.

Any thoughts on a fix for that?

If I find one, I&#039;ll come back and post.</description>
		<content:encoded><![CDATA[<p>Wonderful function &#8212; but the output diverges above 58 on two systems I&#8217;m testing on.  I suspect it&#8217;s because one&#8217;s a 32bit machine, and the other 64.</p>
<p>Any thoughts on a fix for that?</p>
<p>If I find one, I&#8217;ll come back and post.</p>
]]></content:encoded>
	</item>
</channel>
</rss>

