<?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>Random Web Tools &#187; Code</title>
	<atom:link href="http://www.randomtools.net/category/code/feed" rel="self" type="application/rss+xml" />
	<link>http://www.randomtools.net</link>
	<description>Advice and tools from a young web developer</description>
	<lastBuildDate>Fri, 13 Jan 2012 01:08:01 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>How to install PHP Memcache on Windows WAMP, Linux for any operating system (without really installing)</title>
		<link>http://www.randomtools.net/how-to-install-php-memcache-on-windows-wamp-linux-for-any-operating-system-without-really-installing-231.html</link>
		<comments>http://www.randomtools.net/how-to-install-php-memcache-on-windows-wamp-linux-for-any-operating-system-without-really-installing-231.html#comments</comments>
		<pubDate>Wed, 11 Jan 2012 18:30:50 +0000</pubDate>
		<dc:creator>Dan</dc:creator>
				<category><![CDATA[Code]]></category>
		<category><![CDATA[How To's]]></category>
		<category><![CDATA[PHP]]></category>

		<guid isPermaLink="false">http://www.randomtools.net/?p=231</guid>
		<description><![CDATA[I have a site that runs on Linux in production that uses Memcache. Installing Memcache on Linux is a cinch. I was setting this site up in my development environment however (Windows 7 64-bit, with WAMP, specifically Apache 2 and PHP 5.3) and I quickly discovered it&#8217;s not so easy. For the life of me, [...]]]></description>
			<content:encoded><![CDATA[<p>I have a site that runs on Linux in production that uses Memcache. Installing Memcache on Linux is a cinch. I was setting this site up in my development environment however (Windows 7 64-bit, with WAMP, specifically Apache 2 and PHP 5.3) and I quickly discovered it&#8217;s not so easy. For the life of me, I could not find the correct php_memcache.dll file.</p>
<p>After spending a ton of time unsuccessfully install Memcache on my local machine, I realized that I don&#8217;t even need the memory caching functionality of Memcache, I just need the functions to work.</p>
<p>After some thought, I decided to just implement the class and functions that Memcache provides. Following is what I came up with. It just uses a specified directory to store cache in serialized files on the hard drive. Obviously it doesn&#8217;t exactly simulate real production Memcache, but it allows you to work from any box without having to install it.</p>
<p>Here&#8217;s what I came up with:</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">&lt;?php</span>
<span style="color: #666666; font-style: italic;">/*
Fake PHP Memcache class
Use Memcache functions without installing. Useful in development environments.
&nbsp;
Dan Barnett
http://www.randomtools.net/
*/</span>
<span style="color: #000000; font-weight: bold;">class</span> Memcache <span style="color: #009900;">&#123;</span>
	<span style="color: #000000; font-weight: bold;">private</span> <span style="color: #000088;">$cache_dir</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">'C:/path/to/directory/'</span><span style="color: #339933;">;</span>
&nbsp;
	<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000000; font-weight: bold;">function</span> close<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><span style="color: #009900;">&#125;</span>
&nbsp;
	<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000000; font-weight: bold;">function</span> connect<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</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>
&nbsp;
	<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000000; font-weight: bold;">function</span> pconnect<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
		<span style="color: #b1b100;">return</span> <span style="color: #000088;">$this</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">connect</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span>
&nbsp;
	<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000000; font-weight: bold;">function</span> getVersion<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
		<span style="color: #b1b100;">return</span> <span style="color: #339933;">-</span><span style="color: #cc66cc;">1</span><span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span>
&nbsp;
	<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000000; font-weight: bold;">function</span> get<span style="color: #009900;">&#40;</span><span style="color: #000088;">$key</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
		<span style="color: #b1b100;">return</span> <span style="color: #990000;">unserialize</span><span style="color: #009900;">&#40;</span><span style="color: #990000;">file_get_contents</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$this</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">cache_dir</span> <span style="color: #339933;">.</span> <span style="color: #990000;">md5</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$key</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">.</span> <span style="color: #0000ff;">&quot;.txt&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span>
&nbsp;
	<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000000; font-weight: bold;">function</span> set<span style="color: #009900;">&#40;</span><span style="color: #000088;">$key</span><span style="color: #339933;">,</span> <span style="color: #000088;">$value</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
		<span style="color: #b1b100;">return</span> <span style="color: #990000;">file_put_contents</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$this</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">cache_dir</span> <span style="color: #339933;">.</span> <span style="color: #990000;">md5</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$key</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">.</span> <span style="color: #0000ff;">&quot;.txt&quot;</span><span style="color: #339933;">,</span> <span style="color: #990000;">serialize</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$value</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span>
&nbsp;
	<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000000; font-weight: bold;">function</span> <span style="color: #990000;">flush</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
		<span style="color: #b1b100;">foreach</span> <span style="color: #009900;">&#40;</span><span style="color: #990000;">glob</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$this</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">cache_dir</span> <span style="color: #339933;">.</span> <span style="color: #0000ff;">'*.txt'</span><span style="color: #009900;">&#41;</span> <span style="color: #b1b100;">as</span> <span style="color: #000088;">$file</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
			<span style="color: #990000;">unlink</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$file</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
		<span style="color: #009900;">&#125;</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>
&nbsp;
<span style="color: #000000; font-weight: bold;">function</span> <span style="color: #990000;">memcache_close</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><span style="color: #009900;">&#125;</span>
&nbsp;
<span style="color: #000000; font-weight: bold;">function</span> <span style="color: #990000;">memcache_connect</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
	<span style="color: #000000; font-weight: bold;">global</span> <span style="color: #000088;">$memcache</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$memcache</span> <span style="color: #339933;">=</span> <span style="color: #000000; font-weight: bold;">new</span> Memcache<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span>
&nbsp;
<span style="color: #000000; font-weight: bold;">function</span> <span style="color: #990000;">memcache_pconnect</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
	<span style="color: #b1b100;">return</span> <span style="color: #990000;">memcache_connect</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span>
&nbsp;
<span style="color: #000000; font-weight: bold;">function</span> <span style="color: #990000;">memcache_set</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$key</span><span style="color: #339933;">,</span> <span style="color: #000088;">$value</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
	<span style="color: #000000; font-weight: bold;">global</span> <span style="color: #000088;">$memcache</span><span style="color: #339933;">;</span>
	<span style="color: #b1b100;">return</span> <span style="color: #000088;">$memcache</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">set</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$key</span><span style="color: #339933;">,</span> <span style="color: #000088;">$value</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span>
&nbsp;
<span style="color: #000000; font-weight: bold;">function</span> <span style="color: #990000;">memcache_get</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$key</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
	<span style="color: #000000; font-weight: bold;">global</span> <span style="color: #000088;">$memcache</span><span style="color: #339933;">;</span>
	<span style="color: #b1b100;">return</span> <span style="color: #000088;">$memcache</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">get</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$key</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span>
&nbsp;
<span style="color: #000000; font-weight: bold;">function</span> <span style="color: #990000;">memcache_get_version</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
	<span style="color: #000000; font-weight: bold;">global</span> <span style="color: #000088;">$memcache</span><span style="color: #339933;">;</span>
	<span style="color: #b1b100;">return</span> <span style="color: #000088;">$memcache</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">getVersion</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span>
&nbsp;
<span style="color: #000000; font-weight: bold;">function</span> <span style="color: #990000;">memcache_flush</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
	<span style="color: #000000; font-weight: bold;">global</span> <span style="color: #000088;">$memcache</span><span style="color: #339933;">;</span>
	<span style="color: #b1b100;">return</span> <span style="color: #000088;">$memcache</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">flush</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span>
<span style="color: #000000; font-weight: bold;">?&gt;</span></pre></div></div>

<p><div style="width: 300px; height: 250px; margin: 3px;"><script type="text/javascript"><!--
google_ad_client = "pub-1936238606905173";
google_ad_slot = "4013486594";
google_ad_width = 300;
google_ad_height = 250;
//--></script>
<script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"></script>
</div></p>
<div class='bookmarkify'><a name='bookmarkify'></a><div class='title' title='Use these links to share this page with others'>Bookmark this page</div><div class='linkbuttons'><a href='http://del.icio.us/post?url=http://www.randomtools.net/how-to-install-php-memcache-on-windows-wamp-linux-for-any-operating-system-without-really-installing-231.html&amp;title=How to install PHP Memcache on Windows WAMP, Linux for any operating system (without really installing)' title='Save to del.icio.us' onclick='target="_blank";' rel='nofollow'><img src='http://www.randomtools.net/wp-content/plugins/bookmarkify/delicious.png' style='width:16px; height:16px;' alt='[del.icio.us] ' /></a> <a href='http://digg.com/submit?phase=2&amp;url=http://www.randomtools.net/how-to-install-php-memcache-on-windows-wamp-linux-for-any-operating-system-without-really-installing-231.html&amp;title=How to install PHP Memcache on Windows WAMP, Linux for any operating system (without really installing)' title='Digg It!' onclick='target="_blank";' rel='nofollow'><img src='http://www.randomtools.net/wp-content/plugins/bookmarkify/digg.png' style='width:16px; height:16px;' alt='[Digg] ' /></a> <a href='http://www.facebook.com/share.php?u=http://www.randomtools.net/how-to-install-php-memcache-on-windows-wamp-linux-for-any-operating-system-without-really-installing-231.html' title='Save to Facebook' onclick='target="_blank";' rel='nofollow'><img src='http://www.randomtools.net/wp-content/plugins/bookmarkify/facebook.png' style='width:16px; height:16px;' alt='[Facebook] ' /></a> <a href='http://www.google.com/bookmarks/mark?op=edit&amp;output=popup&amp;bkmk=http://www.randomtools.net/how-to-install-php-memcache-on-windows-wamp-linux-for-any-operating-system-without-really-installing-231.html&amp;title=How to install PHP Memcache on Windows WAMP, Linux for any operating system (without really installing)' title='Save to Google Bookmarks' onclick='target="_blank";' rel='nofollow'><img src='http://www.randomtools.net/wp-content/plugins/bookmarkify/google.png' style='width:16px; height:16px;' alt='[Google] ' /></a> <a href='http://reddit.com/submit?url=http://www.randomtools.net/how-to-install-php-memcache-on-windows-wamp-linux-for-any-operating-system-without-really-installing-231.html&amp;title=How to install PHP Memcache on Windows WAMP, Linux for any operating system (without really installing)' title='Reddit' onclick='target="_blank";' rel='nofollow'><img src='http://www.randomtools.net/wp-content/plugins/bookmarkify/reddit.png' style='width:16px; height:16px;' alt='[Reddit] ' /></a> <a href='http://slashdot.org/bookmark.pl?url=http://www.randomtools.net/how-to-install-php-memcache-on-windows-wamp-linux-for-any-operating-system-without-really-installing-231.html&amp;title=How to install PHP Memcache on Windows WAMP, Linux for any operating system (without really installing)' title='Slashdot It!' onclick='target="_blank";' rel='nofollow'><img src='http://www.randomtools.net/wp-content/plugins/bookmarkify/slashdot.png' style='width:16px; height:16px;' alt='[Slashdot] ' /></a> <a href='http://www.stumbleupon.com/submit?url=http://www.randomtools.net/how-to-install-php-memcache-on-windows-wamp-linux-for-any-operating-system-without-really-installing-231.html&amp;title=How to install PHP Memcache on Windows WAMP, Linux for any operating system (without really installing)' title='Stumble It!' onclick='target="_blank";' rel='nofollow'><img src='http://www.randomtools.net/wp-content/plugins/bookmarkify/stumbleupon.png' style='width:16px; height:16px;' alt='[StumbleUpon] ' /></a> </div></div>]]></content:encoded>
			<wfw:commentRss>http://www.randomtools.net/how-to-install-php-memcache-on-windows-wamp-linux-for-any-operating-system-without-really-installing-231.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Android ANR keyDispatchingTimedOut</title>
		<link>http://www.randomtools.net/android-anr-keydispatchingtimedout-178.html</link>
		<comments>http://www.randomtools.net/android-anr-keydispatchingtimedout-178.html#comments</comments>
		<pubDate>Fri, 17 Sep 2010 02:49:21 +0000</pubDate>
		<dc:creator>Dan</dc:creator>
				<category><![CDATA[Code]]></category>

		<guid isPermaLink="false">http://www.randomtools.net/?p=178</guid>
		<description><![CDATA[I recently had some issues with my Mancala app where some users were experiencing frequent force closes and I could not figure out the reason for this behavior. Fortunately, with the help of Android&#39;s relatively new force close reporting features, I was able to get some insight into the issue. The big issue seemed to [...]]]></description>
			<content:encoded><![CDATA[<p><div style="width: 300px; height: 250px; margin: 3px;"><script type="text/javascript"><!--
google_ad_client = "pub-1936238606905173";
google_ad_slot = "4013486594";
google_ad_width = 300;
google_ad_height = 250;
//--></script>
<script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"></script>
</div></p>
<p>I recently had some issues with my Mancala app where some users were experiencing frequent force closes and I could not figure out the reason for this behavior. Fortunately, with the help of Android&#39;s relatively new force close reporting features, I was able to get some insight into the issue. The big issue seemed to be an ANR keyDispatchingTimedOut error, which was something I had no idea about, and Google wasn&#39;t super helpful.</p>
<p>Here&#39;s an example of the &quot;Dalvik threads&quot; that were reported to me in the Android Developer Console. My understanding is that this is a list of threads and their stack traces at the time of the force close.</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
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
</pre></td><td class="code"><pre class="text" style="font-family:monospace;">DALVIK THREADS:
&amp;quot;main&amp;quot; prio=5 tid=1 NATIVE
  | group=&amp;quot;main&amp;quot; sCount=1 dsCount=0 s=N obj=0x4001d8c8 self=0xccc8
  | sysTid=9498 nice=0 sched=0/0 cgrp=default handle=-1345013672
  | schedstat=( 103942869 246185301 151 )
  at java.net.InetAddress.getaddrinfo(Native Method)
  at java.net.InetAddress.lookupHostByName(InetAddress.java:508)
  at java.net.InetAddress.getAllByNameImpl(InetAddress.java:280)
  at java.net.InetAddress.getByName(InetAddress.java:310)
  at java.net.InetSocketAddress.&lt;init&gt;(InetSocketAddress.java:110)
  at java.net.InetSocketAddress.&lt;init&gt;(InetSocketAddress.java:89)
  at org.apache.harmony.luni.internal.net.www.protocol.http.HttpConnection.&lt;init&gt;(HttpConnection.java:62)
  at org.apache.harmony.luni.internal.net.www.protocol.http.HttpConnectionPool.get(HttpConnectionPool.java:88)
  at org.apache.harmony.luni.internal.net.www.protocol.http.HttpURLConnectionImpl.getHTTPConnection(HttpURLConnectionImpl.java:927)
  at org.apache.harmony.luni.internal.net.www.protocol.http.HttpURLConnectionImpl.connect(HttpURLConnectionImpl.java:909)
  at org.apache.harmony.luni.internal.net.www.protocol.http.HttpURLConnectionImpl.getInputStream(HttpURLConnectionImpl.java:1152)
  at com.xoise.mancala.Mancala.checkUpdate(Mancala.java:203)
  at com.xoise.mancala.Mancala.onCreate(Mancala.java:45)
  at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1047)
  at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2627)
  at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2679)
  at android.app.ActivityThread.access$2300(ActivityThread.java:125)
  at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2033)
  at android.os.Handler.dispatchMessage(Handler.java:99)
  at android.os.Looper.loop(Looper.java:123)
  at android.app.ActivityThread.main(ActivityThread.java:4627)
  at java.lang.reflect.Method.invokeNative(Native Method)
  at java.lang.reflect.Method.invoke(Method.java:521)
  at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:868)
  at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:626)
  at dalvik.system.NativeStart.main(Native Method)
&nbsp;
&amp;quot;SoundPoolThread&amp;quot; prio=5 tid=8 NATIVE
  | group=&amp;quot;main&amp;quot; sCount=1 dsCount=0 s=N obj=0x43ee6dc8 self=0x22b020
  | sysTid=9506 nice=0 sched=0/0 cgrp=default handle=1204184
  | schedstat=( 854492 25299072 9 )
  at dalvik.system.NativeStart.run(Native Method)
&nbsp;
&amp;quot;SoundPool&amp;quot; prio=5 tid=9 NATIVE
  | group=&amp;quot;main&amp;quot; sCount=1 dsCount=0 s=N obj=0x43ee6e88 self=0x22b430
  | sysTid=9505 nice=0 sched=0/0 cgrp=default handle=1203920
  | schedstat=( 122071 25207520 2 )
  at dalvik.system.NativeStart.run(Native Method)
&nbsp;
&amp;quot;Binder Thread #2&amp;quot; prio=5 tid=7 NATIVE
  | group=&amp;quot;main&amp;quot; sCount=1 dsCount=0 s=N obj=0x43ecfa48 self=0x13f1f8
  | sysTid=9504 nice=0 sched=0/0 cgrp=default handle=1189136
  | schedstat=( 3265379 22705078 15 )
  at dalvik.system.NativeStart.run(Native Method)
&nbsp;
&amp;quot;Binder Thread #1&amp;quot; prio=5 tid=6 NATIVE
  | group=&amp;quot;main&amp;quot; sCount=1 dsCount=0 s=N obj=0x43ecf988 self=0x125a90
  | sysTid=9503 nice=0 sched=0/0 cgrp=default handle=1202768
  | schedstat=( 4425047 132843018 15 )
  at dalvik.system.NativeStart.run(Native Method)
&nbsp;
&amp;quot;Compiler&amp;quot; daemon prio=5 tid=5 VMWAIT
  | group=&amp;quot;system&amp;quot; sCount=1 dsCount=0 s=N obj=0x43ecd348 self=0x121228
  | sysTid=9502 nice=0 sched=0/0 cgrp=default handle=1184232
  | schedstat=( 1708986 15808104 6 )
  at dalvik.system.NativeStart.run(Native Method)
&nbsp;
&amp;quot;JDWP&amp;quot; daemon prio=5 tid=4 VMWAIT
  | group=&amp;quot;system&amp;quot; sCount=1 dsCount=0 s=N obj=0x43ecd2a0 self=0x120b08
  | sysTid=9501 nice=0 sched=0/0 cgrp=default handle=1184152
  | schedstat=( 2685545 5004884 22 )
  at dalvik.system.NativeStart.run(Native Method)
&nbsp;
&amp;quot;Signal Catcher&amp;quot; daemon prio=5 tid=3 RUNNABLE
  | group=&amp;quot;system&amp;quot; sCount=0 dsCount=0 s=N obj=0x43ecd1e8 self=0x120fa8
  | sysTid=9500 nice=0 sched=0/0 cgrp=default handle=1196024
  | schedstat=( 3875733 5920410 15 )
  at dalvik.system.NativeStart.run(Native Method)
&nbsp;
&amp;quot;HeapWorker&amp;quot; daemon prio=5 tid=2 VMWAIT
  | group=&amp;quot;system&amp;quot; sCount=1 dsCount=0 s=N obj=0x43111d58 self=0x129518
  | sysTid=9499 nice=0 sched=0/0 cgrp=default handle=1185056
  | schedstat=( 27954104 52368162 15 )
  at dalvik.system.NativeStart.run(Native Method)&lt;/init&gt;&lt;/init&gt;&lt;/init&gt;</pre></td></tr></table></div>

<p>This ANR, or Application Not Responding, error occurs when a process on the main thread takes too long (something like 5 seconds). Android kills that process and any related by design to spare the device&#39;s resources.</p>
<p>The solution is to run resource-expensive tasks on another thread, and then post, or update the main thread accordingly. A common use for this is network calls (and this was what my problem was). The following is an example of how to implement this logic, in my case to check if an update is needed:</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
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
</pre></td><td class="code"><pre class="java" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">private</span> <span style="color: #000066; font-weight: bold;">void</span> checkUpdate<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
	SharedPreferences prefs <span style="color: #339933;">=</span> getPreferences<span style="color: #009900;">&#40;</span><span style="color: #cc66cc;">0</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	SharedPreferences.<span style="color: #006633;">Editor</span> editor <span style="color: #339933;">=</span> prefs.<span style="color: #006633;">edit</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
	<span style="color: #000066; font-weight: bold;">long</span> lastUpdateTime <span style="color: #339933;">=</span> prefs.<span style="color: #006633;">getLong</span><span style="color: #009900;">&#40;</span><span style="color: #339933;">&amp;</span>quot<span style="color: #339933;">;</span>lastUpdateTime<span style="color: #339933;">&amp;</span>quot<span style="color: #339933;">;</span>, <span style="color: #cc66cc;">0</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #000066; font-weight: bold;">long</span> time <span style="color: #339933;">=</span> <span style="color: #003399;">System</span>.<span style="color: #006633;">currentTimeMillis</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">/</span> <span style="color: #cc66cc;">1000</span><span style="color: #339933;">;</span>
&nbsp;
	<span style="color: #000000; font-weight: bold;">if</span> <span style="color: #009900;">&#40;</span>lastUpdateTime <span style="color: #339933;">+</span> <span style="color: #cc66cc;">3600</span> <span style="color: #339933;">*</span> <span style="color: #cc66cc;">24</span> <span style="color: #339933;">&amp;</span>lt<span style="color: #339933;">;</span> time<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
		checkNetworkUpdate<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
		editor.<span style="color: #006633;">putLong</span><span style="color: #009900;">&#40;</span><span style="color: #339933;">&amp;</span>quot<span style="color: #339933;">;</span>lastUpdateTime<span style="color: #339933;">&amp;</span>quot<span style="color: #339933;">;</span>, time<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
		editor.<span style="color: #006633;">commit</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span>
<span style="color: #009900;">&#125;</span>
&nbsp;
<span style="color: #000000; font-weight: bold;">protected</span> <span style="color: #000066; font-weight: bold;">void</span> checkNetworkUpdate<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
	<span style="color: #003399;">Thread</span> t <span style="color: #339933;">=</span> <span style="color: #000000; font-weight: bold;">new</span> <span style="color: #003399;">Thread</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
		<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000066; font-weight: bold;">void</span> run<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
			<span style="color: #000000; font-weight: bold;">try</span> <span style="color: #009900;">&#123;</span>
				<span style="color: #003399;">URL</span> updateURL <span style="color: #339933;">=</span> <span style="color: #000000; font-weight: bold;">new</span> <span style="color: #003399;">URL</span><span style="color: #009900;">&#40;</span><span style="color: #339933;">&amp;</span>quot<span style="color: #339933;">;</span>http<span style="color: #339933;">:</span><span style="color: #666666; font-style: italic;">//www.updateurl.com/&amp;quot;);       </span>
				<span style="color: #003399;">URLConnection</span> conn <span style="color: #339933;">=</span> updateURL.<span style="color: #006633;">openConnection</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
				conn.<span style="color: #006633;">setConnectTimeout</span><span style="color: #009900;">&#40;</span><span style="color: #cc66cc;">3000</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
				Scanner scanner <span style="color: #339933;">=</span> <span style="color: #000000; font-weight: bold;">new</span> Scanner<span style="color: #009900;">&#40;</span>conn.<span style="color: #006633;">getInputStream</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> 
				scanner.<span style="color: #006633;">useDelimiter</span><span style="color: #009900;">&#40;</span><span style="color: #339933;">&amp;</span>quot<span style="color: #339933;">;</span>\\n<span style="color: #339933;">&amp;</span>quot<span style="color: #339933;">;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
				<span style="color: #000066; font-weight: bold;">int</span> curVersion <span style="color: #339933;">=</span> getPackageManager<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span>.<span style="color: #006633;">getPackageInfo</span><span style="color: #009900;">&#40;</span><span style="color: #339933;">&amp;</span>quot<span style="color: #339933;">;</span>your.<span style="color: #000000; font-weight: bold;">package</span>.<span style="color: #006633;">name</span><span style="color: #339933;">&amp;</span>quot<span style="color: #339933;">;</span>, <span style="color: #cc66cc;">0</span><span style="color: #009900;">&#41;</span>.<span style="color: #006633;">versionCode</span><span style="color: #339933;">;</span>
				<span style="color: #000066; font-weight: bold;">int</span> newVersion <span style="color: #339933;">=</span> <span style="color: #cc66cc;">0</span><span style="color: #339933;">;</span>
				<span style="color: #000000; font-weight: bold;">if</span> <span style="color: #009900;">&#40;</span>scanner.<span style="color: #006633;">hasNext</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span>
					newVersion <span style="color: #339933;">=</span> <span style="color: #003399;">Integer</span>.<span style="color: #006633;">valueOf</span><span style="color: #009900;">&#40;</span>scanner.<span style="color: #006633;">next</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
				<span style="color: #000000; font-weight: bold;">final</span> <span style="color: #000066; font-weight: bold;">boolean</span> displayUpdate <span style="color: #339933;">=</span> newVersion <span style="color: #339933;">&amp;</span>gt<span style="color: #339933;">;</span> curVersion<span style="color: #339933;">;</span>
&nbsp;
				runOnUiThread<span style="color: #009900;">&#40;</span><span style="color: #000000; font-weight: bold;">new</span> <span style="color: #003399;">Runnable</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
					<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000066; font-weight: bold;">void</span> run<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
						handleNetworkReply<span style="color: #009900;">&#40;</span>displayUpdate<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
					<span style="color: #009900;">&#125;</span>
				<span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
			<span style="color: #009900;">&#125;</span> <span style="color: #000000; font-weight: bold;">catch</span> <span style="color: #009900;">&#40;</span><span style="color: #003399;">Exception</span> e<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><span style="color: #009900;">&#125;</span>
		<span style="color: #009900;">&#125;</span>
	<span style="color: #009900;">&#125;</span><span style="color: #339933;">;</span>
	t.<span style="color: #006633;">start</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span>
&nbsp;
<span style="color: #000000; font-weight: bold;">private</span> <span style="color: #000066; font-weight: bold;">void</span> handleNetworkReply<span style="color: #009900;">&#40;</span><span style="color: #000066; font-weight: bold;">boolean</span> displayUpdate<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
	<span style="color: #000000; font-weight: bold;">if</span> <span style="color: #009900;">&#40;</span>displayUpdate<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
		<span style="color: #009900;">&#40;</span><span style="color: #000000; font-weight: bold;">new</span> AlertDialog.<span style="color: #006633;">Builder</span><span style="color: #009900;">&#40;</span><span style="color: #000000; font-weight: bold;">this</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span>.<span style="color: #006633;">setMessage</span><span style="color: #009900;">&#40;</span><span style="color: #339933;">&amp;</span>quot<span style="color: #339933;">;</span>An update is available<span style="color: #339933;">!</span>\n\nOpen Android Market to see the details<span style="color: #339933;">?&amp;</span>quot<span style="color: #339933;">;</span><span style="color: #009900;">&#41;</span>
			.<span style="color: #006633;">setTitle</span><span style="color: #009900;">&#40;</span><span style="color: #339933;">&amp;</span>quot<span style="color: #339933;">;</span>Update Available<span style="color: #339933;">&amp;</span>quot<span style="color: #339933;">;</span><span style="color: #009900;">&#41;</span>
			.<span style="color: #006633;">setPositiveButton</span><span style="color: #009900;">&#40;</span><span style="color: #339933;">&amp;</span>quot<span style="color: #339933;">;</span>Yes<span style="color: #339933;">&amp;</span>quot<span style="color: #339933;">;</span>, <span style="color: #000000; font-weight: bold;">new</span> DialogInterface.<span style="color: #006633;">OnClickListener</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
				<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000066; font-weight: bold;">void</span> onClick<span style="color: #009900;">&#40;</span>DialogInterface dialog, <span style="color: #000066; font-weight: bold;">int</span> whichButton<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
					Intent intent <span style="color: #339933;">=</span> <span style="color: #000000; font-weight: bold;">new</span> Intent<span style="color: #009900;">&#40;</span>Intent.<span style="color: #006633;">ACTION_VIEW</span>, Uri.<span style="color: #006633;">parse</span><span style="color: #009900;">&#40;</span><span style="color: #339933;">&amp;</span>quot<span style="color: #339933;">;</span>market<span style="color: #339933;">:</span><span style="color: #666666; font-style: italic;">//details?id=your.package.name&amp;quot;));</span>
					startActivity<span style="color: #009900;">&#40;</span>intent<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
				<span style="color: #009900;">&#125;</span>
			<span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span>
			.<span style="color: #006633;">setNegativeButton</span><span style="color: #009900;">&#40;</span><span style="color: #339933;">&amp;</span>quot<span style="color: #339933;">;</span>No<span style="color: #339933;">&amp;</span>quot<span style="color: #339933;">;</span>, <span style="color: #000066; font-weight: bold;">null</span><span style="color: #009900;">&#41;</span>
			.<span style="color: #006633;">create</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span>
			.<span style="color: #006633;">show</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span>
<span style="color: #009900;">&#125;</span></pre></td></tr></table></div>

<p>Then just call checkUpdate() to perform the task. Note the major points of importance here being the Thread object with a run() method and the runOnUiThread() method of the Activity, which allows you to post data to the main UI thread.</p>
<div class='bookmarkify'><a name='bookmarkify'></a><div class='title' title='Use these links to share this page with others'>Bookmark this page</div><div class='linkbuttons'><a href='http://del.icio.us/post?url=http://www.randomtools.net/android-anr-keydispatchingtimedout-178.html&amp;title=Android ANR keyDispatchingTimedOut' title='Save to del.icio.us' onclick='target="_blank";' rel='nofollow'><img src='http://www.randomtools.net/wp-content/plugins/bookmarkify/delicious.png' style='width:16px; height:16px;' alt='[del.icio.us] ' /></a> <a href='http://digg.com/submit?phase=2&amp;url=http://www.randomtools.net/android-anr-keydispatchingtimedout-178.html&amp;title=Android ANR keyDispatchingTimedOut' title='Digg It!' onclick='target="_blank";' rel='nofollow'><img src='http://www.randomtools.net/wp-content/plugins/bookmarkify/digg.png' style='width:16px; height:16px;' alt='[Digg] ' /></a> <a href='http://www.facebook.com/share.php?u=http://www.randomtools.net/android-anr-keydispatchingtimedout-178.html' title='Save to Facebook' onclick='target="_blank";' rel='nofollow'><img src='http://www.randomtools.net/wp-content/plugins/bookmarkify/facebook.png' style='width:16px; height:16px;' alt='[Facebook] ' /></a> <a href='http://www.google.com/bookmarks/mark?op=edit&amp;output=popup&amp;bkmk=http://www.randomtools.net/android-anr-keydispatchingtimedout-178.html&amp;title=Android ANR keyDispatchingTimedOut' title='Save to Google Bookmarks' onclick='target="_blank";' rel='nofollow'><img src='http://www.randomtools.net/wp-content/plugins/bookmarkify/google.png' style='width:16px; height:16px;' alt='[Google] ' /></a> <a href='http://reddit.com/submit?url=http://www.randomtools.net/android-anr-keydispatchingtimedout-178.html&amp;title=Android ANR keyDispatchingTimedOut' title='Reddit' onclick='target="_blank";' rel='nofollow'><img src='http://www.randomtools.net/wp-content/plugins/bookmarkify/reddit.png' style='width:16px; height:16px;' alt='[Reddit] ' /></a> <a href='http://slashdot.org/bookmark.pl?url=http://www.randomtools.net/android-anr-keydispatchingtimedout-178.html&amp;title=Android ANR keyDispatchingTimedOut' title='Slashdot It!' onclick='target="_blank";' rel='nofollow'><img src='http://www.randomtools.net/wp-content/plugins/bookmarkify/slashdot.png' style='width:16px; height:16px;' alt='[Slashdot] ' /></a> <a href='http://www.stumbleupon.com/submit?url=http://www.randomtools.net/android-anr-keydispatchingtimedout-178.html&amp;title=Android ANR keyDispatchingTimedOut' title='Stumble It!' onclick='target="_blank";' rel='nofollow'><img src='http://www.randomtools.net/wp-content/plugins/bookmarkify/stumbleupon.png' style='width:16px; height:16px;' alt='[StumbleUpon] ' /></a> </div></div>]]></content:encoded>
			<wfw:commentRss>http://www.randomtools.net/android-anr-keydispatchingtimedout-178.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How to Hide Android WebView Highlight Border (or change it&#8217;s color)</title>
		<link>http://www.randomtools.net/how-to-hide-android-webview-highlight-border-or-change-its-color-142.html</link>
		<comments>http://www.randomtools.net/how-to-hide-android-webview-highlight-border-or-change-its-color-142.html#comments</comments>
		<pubDate>Sat, 27 Feb 2010 23:20:37 +0000</pubDate>
		<dc:creator>Dan</dc:creator>
				<category><![CDATA[Code]]></category>
		<category><![CDATA[How To's]]></category>

		<guid isPermaLink="false">http://www.randomtools.net/?p=142</guid>
		<description><![CDATA[Here&#39;s one that had me at a loss for a long time that I just figured out. You can easily remove the highlight border (the border that comes up when an element is focused) or change it&#39;s color in a WebView with CSS! The WebKit-specific property &#34;-webkit-tap-highlight-color&#34; is what you&#39;re looking for. The following line [...]]]></description>
			<content:encoded><![CDATA[<p>Here&#39;s one that had me at a loss for a long time that I just figured out. You can easily remove the highlight border (the border that comes up when an element is focused) or change it&#39;s color in a WebView with CSS! The WebKit-specific property &quot;-webkit-tap-highlight-color&quot; is what you&#39;re looking for.</p>
<p>The following line will disable it on a page completely:</p>

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>1
2
3
</pre></td><td class="code"><pre class="css" style="font-family:monospace;"><span style="color: #00AA00;">*</span> <span style="color: #00AA00;">&#123;</span>
	-webkit-tap-highlight-<span style="color: #000000; font-weight: bold;">color</span><span style="color: #00AA00;">:</span> rgba<span style="color: #00AA00;">&#40;</span><span style="color: #cc66cc;">0</span><span style="color: #00AA00;">,</span> <span style="color: #cc66cc;">0</span><span style="color: #00AA00;">,</span> <span style="color: #cc66cc;">0</span><span style="color: #00AA00;">,</span> <span style="color: #cc66cc;">0</span><span style="color: #00AA00;">&#41;</span><span style="color: #00AA00;">;</span>	
<span style="color: #00AA00;">&#125;</span></pre></td></tr></table></div>

<p>rgba() is just like rgb(), but it takes a 4th parameter for opacity. It&#39;s my belief that this would probably work for iPhone WebView&#39;s as well, since both Chrome and Safari are based off of WebKit.</p>
<div style="width: 300px; height: 300px;"><div style="width: 300px; height: 250px; margin: 3px;"><script type="text/javascript"><!--
google_ad_client = "pub-1936238606905173";
google_ad_slot = "4013486594";
google_ad_width = 300;
google_ad_height = 250;
//--></script>
<script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"></script>
</div></div>
<div class='bookmarkify'><a name='bookmarkify'></a><div class='title' title='Use these links to share this page with others'>Bookmark this page</div><div class='linkbuttons'><a href='http://del.icio.us/post?url=http://www.randomtools.net/how-to-hide-android-webview-highlight-border-or-change-its-color-142.html&amp;title=How to Hide Android WebView Highlight Border (or change it&#8217;s color)' title='Save to del.icio.us' onclick='target="_blank";' rel='nofollow'><img src='http://www.randomtools.net/wp-content/plugins/bookmarkify/delicious.png' style='width:16px; height:16px;' alt='[del.icio.us] ' /></a> <a href='http://digg.com/submit?phase=2&amp;url=http://www.randomtools.net/how-to-hide-android-webview-highlight-border-or-change-its-color-142.html&amp;title=How to Hide Android WebView Highlight Border (or change it&#8217;s color)' title='Digg It!' onclick='target="_blank";' rel='nofollow'><img src='http://www.randomtools.net/wp-content/plugins/bookmarkify/digg.png' style='width:16px; height:16px;' alt='[Digg] ' /></a> <a href='http://www.facebook.com/share.php?u=http://www.randomtools.net/how-to-hide-android-webview-highlight-border-or-change-its-color-142.html' title='Save to Facebook' onclick='target="_blank";' rel='nofollow'><img src='http://www.randomtools.net/wp-content/plugins/bookmarkify/facebook.png' style='width:16px; height:16px;' alt='[Facebook] ' /></a> <a href='http://www.google.com/bookmarks/mark?op=edit&amp;output=popup&amp;bkmk=http://www.randomtools.net/how-to-hide-android-webview-highlight-border-or-change-its-color-142.html&amp;title=How to Hide Android WebView Highlight Border (or change it&#8217;s color)' title='Save to Google Bookmarks' onclick='target="_blank";' rel='nofollow'><img src='http://www.randomtools.net/wp-content/plugins/bookmarkify/google.png' style='width:16px; height:16px;' alt='[Google] ' /></a> <a href='http://reddit.com/submit?url=http://www.randomtools.net/how-to-hide-android-webview-highlight-border-or-change-its-color-142.html&amp;title=How to Hide Android WebView Highlight Border (or change it&#8217;s color)' title='Reddit' onclick='target="_blank";' rel='nofollow'><img src='http://www.randomtools.net/wp-content/plugins/bookmarkify/reddit.png' style='width:16px; height:16px;' alt='[Reddit] ' /></a> <a href='http://slashdot.org/bookmark.pl?url=http://www.randomtools.net/how-to-hide-android-webview-highlight-border-or-change-its-color-142.html&amp;title=How to Hide Android WebView Highlight Border (or change it&#8217;s color)' title='Slashdot It!' onclick='target="_blank";' rel='nofollow'><img src='http://www.randomtools.net/wp-content/plugins/bookmarkify/slashdot.png' style='width:16px; height:16px;' alt='[Slashdot] ' /></a> <a href='http://www.stumbleupon.com/submit?url=http://www.randomtools.net/how-to-hide-android-webview-highlight-border-or-change-its-color-142.html&amp;title=How to Hide Android WebView Highlight Border (or change it&#8217;s color)' title='Stumble It!' onclick='target="_blank";' rel='nofollow'><img src='http://www.randomtools.net/wp-content/plugins/bookmarkify/stumbleupon.png' style='width:16px; height:16px;' alt='[StumbleUpon] ' /></a> </div></div>]]></content:encoded>
			<wfw:commentRss>http://www.randomtools.net/how-to-hide-android-webview-highlight-border-or-change-its-color-142.html/feed</wfw:commentRss>
		<slash:comments>9</slash:comments>
		</item>
		<item>
		<title>PHP RSS Parser &#8211; RSS Reader Class for PHP</title>
		<link>http://www.randomtools.net/php-rss-parser-rss-reader-class-for-php-133.html</link>
		<comments>http://www.randomtools.net/php-rss-parser-rss-reader-class-for-php-133.html#comments</comments>
		<pubDate>Mon, 22 Feb 2010 05:49:24 +0000</pubDate>
		<dc:creator>Dan</dc:creator>
				<category><![CDATA[Code]]></category>

		<guid isPermaLink="false">http://www.randomtools.net/?p=133</guid>
		<description><![CDATA[Just had to create a quick RSS parser for PHP and thought I&#39;d post my solution. The implementation and class follows. &#60;?php $rss = new RSSReader('http://news.google.com/?output=rss'); while ($rss -&#62; hasNext()) print_r($rss -&#62; next()); ?&#62; &#60;?php class RSSReader { var $xml = null; var $pos = 0; var $count = 0; function __construct($feed_url) { $this -&#62; [...]]]></description>
			<content:encoded><![CDATA[<p>Just had to create a quick RSS parser for PHP and thought I&#39;d post my solution. The implementation and class follows.</p>
<pre class="brush: php">&lt;?php
$rss = new RSSReader('http://news.google.com/?output=rss');
while ($rss -&gt; hasNext())
	print_r($rss -&gt; next());
?&gt;</pre>
<div style="width: 300px; height: 300px; clear: both;"><div style="width: 300px; height: 250px; margin: 3px;"><script type="text/javascript"><!--
google_ad_client = "pub-1936238606905173";
google_ad_slot = "4013486594";
google_ad_width = 300;
google_ad_height = 250;
//--></script>
<script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"></script>
</div></div>
<pre class="brush: php">&lt;?php
class RSSReader {
	var $xml = null;
	var $pos = 0;
	var $count = 0;

	function __construct($feed_url) {
		$this -&gt; load_url($feed_url);
	}

	function load_url($feed_url) {
		$this -&gt; load_string(file_get_contents($feed_url));
	}

	function load_string($feed_string) {
		$this -&gt; xml = simplexml_load_string(str_replace('content:encoded', 'content_encoded', $feed_string));
		$this -&gt; pos = 0;
		$this -&gt; count = count($this -&gt; xml -&gt; channel -&gt; item);
	}

	function get_title() {
		return $this -&gt; xml -&gt; channel -&gt; title;
	}

	function get_link() {
		return $this -&gt; xml -&gt; channel -&gt; link;
	}

	function get_pubdate() {
		return $this -&gt; xml -&gt; channel -&gt; pubdate;
	}

	function hasNext() {
		return $this -&gt; count &gt; $this -&gt; pos;
	}

	function next() {
		$obj = $this -&gt; xml -&gt; channel -&gt; item[$this -&gt; pos++];
		return array(
			'title' =&gt; (string) $obj -&gt; title,
			'link' =&gt; (string) $obj -&gt; link,
			'description' =&gt; (string) $obj -&gt; description,
			'content' =&gt; (string) $obj -&gt; content_encoded,
			'pubDate' =&gt; strtotime($obj -&gt; pubDate),
		);
	}
}
?&gt;</pre>
<div class='bookmarkify'><a name='bookmarkify'></a><div class='title' title='Use these links to share this page with others'>Bookmark this page</div><div class='linkbuttons'><a href='http://del.icio.us/post?url=http://www.randomtools.net/php-rss-parser-rss-reader-class-for-php-133.html&amp;title=PHP RSS Parser &#8211; RSS Reader Class for PHP' title='Save to del.icio.us' onclick='target="_blank";' rel='nofollow'><img src='http://www.randomtools.net/wp-content/plugins/bookmarkify/delicious.png' style='width:16px; height:16px;' alt='[del.icio.us] ' /></a> <a href='http://digg.com/submit?phase=2&amp;url=http://www.randomtools.net/php-rss-parser-rss-reader-class-for-php-133.html&amp;title=PHP RSS Parser &#8211; RSS Reader Class for PHP' title='Digg It!' onclick='target="_blank";' rel='nofollow'><img src='http://www.randomtools.net/wp-content/plugins/bookmarkify/digg.png' style='width:16px; height:16px;' alt='[Digg] ' /></a> <a href='http://www.facebook.com/share.php?u=http://www.randomtools.net/php-rss-parser-rss-reader-class-for-php-133.html' title='Save to Facebook' onclick='target="_blank";' rel='nofollow'><img src='http://www.randomtools.net/wp-content/plugins/bookmarkify/facebook.png' style='width:16px; height:16px;' alt='[Facebook] ' /></a> <a href='http://www.google.com/bookmarks/mark?op=edit&amp;output=popup&amp;bkmk=http://www.randomtools.net/php-rss-parser-rss-reader-class-for-php-133.html&amp;title=PHP RSS Parser &#8211; RSS Reader Class for PHP' title='Save to Google Bookmarks' onclick='target="_blank";' rel='nofollow'><img src='http://www.randomtools.net/wp-content/plugins/bookmarkify/google.png' style='width:16px; height:16px;' alt='[Google] ' /></a> <a href='http://reddit.com/submit?url=http://www.randomtools.net/php-rss-parser-rss-reader-class-for-php-133.html&amp;title=PHP RSS Parser &#8211; RSS Reader Class for PHP' title='Reddit' onclick='target="_blank";' rel='nofollow'><img src='http://www.randomtools.net/wp-content/plugins/bookmarkify/reddit.png' style='width:16px; height:16px;' alt='[Reddit] ' /></a> <a href='http://slashdot.org/bookmark.pl?url=http://www.randomtools.net/php-rss-parser-rss-reader-class-for-php-133.html&amp;title=PHP RSS Parser &#8211; RSS Reader Class for PHP' title='Slashdot It!' onclick='target="_blank";' rel='nofollow'><img src='http://www.randomtools.net/wp-content/plugins/bookmarkify/slashdot.png' style='width:16px; height:16px;' alt='[Slashdot] ' /></a> <a href='http://www.stumbleupon.com/submit?url=http://www.randomtools.net/php-rss-parser-rss-reader-class-for-php-133.html&amp;title=PHP RSS Parser &#8211; RSS Reader Class for PHP' title='Stumble It!' onclick='target="_blank";' rel='nofollow'><img src='http://www.randomtools.net/wp-content/plugins/bookmarkify/stumbleupon.png' style='width:16px; height:16px;' alt='[StumbleUpon] ' /></a> </div></div>]]></content:encoded>
			<wfw:commentRss>http://www.randomtools.net/php-rss-parser-rss-reader-class-for-php-133.html/feed</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>How To Convert Large XML Files to CSV</title>
		<link>http://www.randomtools.net/how-to-convert-large-xml-files-to-csv-78.html</link>
		<comments>http://www.randomtools.net/how-to-convert-large-xml-files-to-csv-78.html#comments</comments>
		<pubDate>Fri, 02 Oct 2009 03:45:24 +0000</pubDate>
		<dc:creator>Dan</dc:creator>
				<category><![CDATA[Code]]></category>
		<category><![CDATA[How To's]]></category>
		<category><![CDATA[Tools]]></category>

		<guid isPermaLink="false">http://www.randomtools.net/?p=78</guid>
		<description><![CDATA[&#160;I usually struggle with convert very large XML files to other formats just because they are in a dynamic format and most programs you find run out of memory before properly parsing them.&#160;Well, I&#39;m happy to say, I found a FAST and EASY solution. Of course this will work for small files as well as [...]]]></description>
			<content:encoded><![CDATA[<div style="float: right; width: 300px; height: 250px; margin: 5px;"><div style="width: 300px; height: 250px; margin: 3px;"><script type="text/javascript"><!--
google_ad_client = "pub-1936238606905173";
google_ad_slot = "4013486594";
google_ad_width = 300;
google_ad_height = 250;
//--></script>
<script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"></script>
</div></div>
<p>&nbsp;I usually struggle with convert very large XML files to other formats just because they are in a dynamic format and most programs you find run out of memory before properly parsing them.&nbsp;Well, I&#39;m happy to say, I found a FAST and EASY solution. Of course this will work for small files as well as big files.</p>
<p>You&#39;ll want to grab a copy of the <a href="http://www.microsoft.com/downloads/details.aspx?FamilyID=2FB55371-C94E-4373-B0E9-DB4816552E41&amp;displaylang=en" rel="nofollow">msxsl</a> command line utility from Microsoft.</p>
<p>After you&#39;ve got that, you&#39;ll need to setup a XSL file to tell the program how to format your file. If you&#39;re unfamiliar with XSL, you can familiarize yourself <a href="http://www.w3schools.com/xsl/">here</a>.</p>
<p>After you&#39;ve got your XSL file created, it&#39;s a simple command line entry:</p>
<pre class="brush: vb">msxsl xml_file.xml xsl_file.xsl -o output_file.csv</pre>
<p>The following is a sample XML and XSL file that I used.</p>
<p>XML File:</p>
<pre class="brush: xml:showcolumns"><catalog>
	<content>
		<contentid>772500</contentid>
		<createdate>Tue, 20 Jan 2009 16:28:08 CST</createdate>
		<lastupdatedate>Tue, 20 Jan 2009 16:51:01 CST</lastupdatedate>

		<description>
		<artist>
			<id>61951</id>
			<name>The Hills Season 1</name>
		</artist>
	</description></content>
	<content>
		<contentid>773000</contentid>
		<createdate>Tue, 20 Jan 2009 16:28:08 CST</createdate>
		<lastupdatedate>Tue, 20 Jan 2009 16:53:54 CST</lastupdatedate>

		<description>
		<artist>
			<id>61926</id>
			<name>Hogan Knows Best Season 2</name>
		</artist>
	</description></content>
	<content>
		<contentid>775500</contentid>
		<createdate>Thu, 22 Jan 2009 14:49:12 CST</createdate>
		<lastupdatedate>Thu, 22 Jan 2009 14:51:35 CST</lastupdatedate>

		<description>
		<artist>
			<id>62068</id>
			<name>Carlos Mencia 2007</name>
		</artist>
		<category>
			<id>1402</id>
			<name>Comedy Central</name>
		</category>
	</description></content>
</catalog></pre>
<p>XSL File (Creates tab-delimited file)</p>
<pre class="brush: xml"><xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
	<xsl:template match="/">
		<xsl:for-each select="catalog/content">
			<xsl:value-of select="title"><xsl:text>	</xsl:text><xsl:value-of select="artist/name"><xsl:text>
</xsl:text>
		</xsl:value-of></xsl:value-of></xsl:for-each>
	</xsl:template>
</xsl:stylesheet></pre>
<div class='bookmarkify'><a name='bookmarkify'></a><div class='title' title='Use these links to share this page with others'>Bookmark this page</div><div class='linkbuttons'><a href='http://del.icio.us/post?url=http://www.randomtools.net/how-to-convert-large-xml-files-to-csv-78.html&amp;title=How To Convert Large XML Files to CSV' title='Save to del.icio.us' onclick='target="_blank";' rel='nofollow'><img src='http://www.randomtools.net/wp-content/plugins/bookmarkify/delicious.png' style='width:16px; height:16px;' alt='[del.icio.us] ' /></a> <a href='http://digg.com/submit?phase=2&amp;url=http://www.randomtools.net/how-to-convert-large-xml-files-to-csv-78.html&amp;title=How To Convert Large XML Files to CSV' title='Digg It!' onclick='target="_blank";' rel='nofollow'><img src='http://www.randomtools.net/wp-content/plugins/bookmarkify/digg.png' style='width:16px; height:16px;' alt='[Digg] ' /></a> <a href='http://www.facebook.com/share.php?u=http://www.randomtools.net/how-to-convert-large-xml-files-to-csv-78.html' title='Save to Facebook' onclick='target="_blank";' rel='nofollow'><img src='http://www.randomtools.net/wp-content/plugins/bookmarkify/facebook.png' style='width:16px; height:16px;' alt='[Facebook] ' /></a> <a href='http://www.google.com/bookmarks/mark?op=edit&amp;output=popup&amp;bkmk=http://www.randomtools.net/how-to-convert-large-xml-files-to-csv-78.html&amp;title=How To Convert Large XML Files to CSV' title='Save to Google Bookmarks' onclick='target="_blank";' rel='nofollow'><img src='http://www.randomtools.net/wp-content/plugins/bookmarkify/google.png' style='width:16px; height:16px;' alt='[Google] ' /></a> <a href='http://reddit.com/submit?url=http://www.randomtools.net/how-to-convert-large-xml-files-to-csv-78.html&amp;title=How To Convert Large XML Files to CSV' title='Reddit' onclick='target="_blank";' rel='nofollow'><img src='http://www.randomtools.net/wp-content/plugins/bookmarkify/reddit.png' style='width:16px; height:16px;' alt='[Reddit] ' /></a> <a href='http://slashdot.org/bookmark.pl?url=http://www.randomtools.net/how-to-convert-large-xml-files-to-csv-78.html&amp;title=How To Convert Large XML Files to CSV' title='Slashdot It!' onclick='target="_blank";' rel='nofollow'><img src='http://www.randomtools.net/wp-content/plugins/bookmarkify/slashdot.png' style='width:16px; height:16px;' alt='[Slashdot] ' /></a> <a href='http://www.stumbleupon.com/submit?url=http://www.randomtools.net/how-to-convert-large-xml-files-to-csv-78.html&amp;title=How To Convert Large XML Files to CSV' title='Stumble It!' onclick='target="_blank";' rel='nofollow'><img src='http://www.randomtools.net/wp-content/plugins/bookmarkify/stumbleupon.png' style='width:16px; height:16px;' alt='[StumbleUpon] ' /></a> </div></div>]]></content:encoded>
			<wfw:commentRss>http://www.randomtools.net/how-to-convert-large-xml-files-to-csv-78.html/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>PHP File-System Cache</title>
		<link>http://www.randomtools.net/php-file-system-cache-58.html</link>
		<comments>http://www.randomtools.net/php-file-system-cache-58.html#comments</comments>
		<pubDate>Tue, 25 Aug 2009 00:22:44 +0000</pubDate>
		<dc:creator>Dan</dc:creator>
				<category><![CDATA[Code]]></category>
		<category><![CDATA[Web Tools]]></category>

		<guid isPermaLink="false">http://www.randomtools.net/?p=58</guid>
		<description><![CDATA[I&#8217;m just sharing a couple of functions I created a while back to cache some resource-intensive processed dada for quick and easy access. This is pretty ideal for large amounts of data and it&#8217;s very simple to set up. The beauty of this is that you can store just about any data type &#8211; it [...]]]></description>
			<content:encoded><![CDATA[<div style="width: 300px; height: 250px; margin: 5px; float: right;"><div style="width: 300px; height: 250px; margin: 3px;"><script type="text/javascript"><!--
google_ad_client = "pub-1936238606905173";
google_ad_slot = "4013486594";
google_ad_width = 300;
google_ad_height = 250;
//--></script>
<script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"></script>
</div></div>
<p>I&#8217;m just sharing a couple of functions I created a while back to cache some resource-intensive processed dada for quick and easy access. This is pretty ideal for large amounts of data and it&#8217;s very simple to set up. The beauty of this is that you can store just about any data type &#8211; it doesn&#8217;t have to be a string.</p>
<p>Just setup the cache directory to have proper read/write permissions (preferably in a non-accessible from web directory). Then use the two functions.</p>
<p style="clear: both;"><strong>Example usage:</strong></p>

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>1
2
3
4
5
6
7
8
9
</pre></td><td class="code"><pre class="php" style="font-family:monospace;"><span style="color: #666666; font-style: italic;">// The 2nd argument, $hours is how long to retain data before getting new</span>
<span style="color: #000088;">$contents</span> <span style="color: #339933;">=</span> get_cache<span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'TEST_KEY'</span><span style="color: #339933;">,</span> <span style="color: #cc66cc;">24</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;">$contents</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: #666666; font-style: italic;">// This is where you'd get data from an API, DB or whatever</span>
	<span style="color: #000088;">$contents</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">'Just some example contents'</span><span style="color: #339933;">;</span>
	set_cache<span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'TEST_KEY'</span><span style="color: #339933;">,</span> <span style="color: #000088;">$contents</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span>
<span style="color: #b1b100;">echo</span> <span style="color: #000088;">$contents</span><span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span></pre></td></tr></table></div>

<p><strong>Code:</strong></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
</pre></td><td class="code"><pre class="php" style="font-family:monospace;"><span style="color: #990000;">define</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'CACHE_DIR'</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'cache/'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #666666; font-style: italic;">// Include trailing slash</span>
&nbsp;
<span style="color: #000000; font-weight: bold;">function</span> get_cache<span style="color: #009900;">&#40;</span><span style="color: #000088;">$key</span><span style="color: #339933;">,</span> <span style="color: #000088;">$hours</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
	<span style="color: #000088;">$file</span> <span style="color: #339933;">=</span> CACHE_DIR <span style="color: #339933;">.</span> <span style="color: #990000;">md5</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$key</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">.</span> <span style="color: #0000ff;">'.cache'</span><span style="color: #339933;">;</span>
	<span style="color: #b1b100;">if</span> <span style="color: #009900;">&#40;</span><span style="color: #339933;">!</span><span style="color: #990000;">file_exists</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$file</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">||</span> <span style="color: #990000;">filemtime</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$file</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">&amp;</span>lt<span style="color: #339933;">;</span> <span style="color: #990000;">time</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">-</span> <span style="color: #000088;">$hours</span> <span style="color: #339933;">*</span> <span style="color: #cc66cc;">3600</span><span style="color: #009900;">&#41;</span>
		<span style="color: #b1b100;">return</span> <span style="color: #009900; font-weight: bold;">false</span><span style="color: #339933;">;</span>
	<span style="color: #b1b100;">return</span> <span style="color: #990000;">unserialize</span><span style="color: #009900;">&#40;</span><span style="color: #990000;">file_get_contents</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$file</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span>
&nbsp;
<span style="color: #000000; font-weight: bold;">function</span> set_cache<span style="color: #009900;">&#40;</span><span style="color: #000088;">$key</span><span style="color: #339933;">,</span> <span style="color: #000088;">$value</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
	<span style="color: #000088;">$file</span> <span style="color: #339933;">=</span> CACHE_DIR <span style="color: #339933;">.</span> <span style="color: #990000;">md5</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$key</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">.</span> <span style="color: #0000ff;">'.cache'</span><span style="color: #339933;">;</span>
	<span style="color: #990000;">file_put_contents</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$file</span><span style="color: #339933;">,</span> <span style="color: #990000;">serialize</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$value</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span></pre></td></tr></table></div>

<div class='bookmarkify'><a name='bookmarkify'></a><div class='title' title='Use these links to share this page with others'>Bookmark this page</div><div class='linkbuttons'><a href='http://del.icio.us/post?url=http://www.randomtools.net/php-file-system-cache-58.html&amp;title=PHP File-System Cache' title='Save to del.icio.us' onclick='target="_blank";' rel='nofollow'><img src='http://www.randomtools.net/wp-content/plugins/bookmarkify/delicious.png' style='width:16px; height:16px;' alt='[del.icio.us] ' /></a> <a href='http://digg.com/submit?phase=2&amp;url=http://www.randomtools.net/php-file-system-cache-58.html&amp;title=PHP File-System Cache' title='Digg It!' onclick='target="_blank";' rel='nofollow'><img src='http://www.randomtools.net/wp-content/plugins/bookmarkify/digg.png' style='width:16px; height:16px;' alt='[Digg] ' /></a> <a href='http://www.facebook.com/share.php?u=http://www.randomtools.net/php-file-system-cache-58.html' title='Save to Facebook' onclick='target="_blank";' rel='nofollow'><img src='http://www.randomtools.net/wp-content/plugins/bookmarkify/facebook.png' style='width:16px; height:16px;' alt='[Facebook] ' /></a> <a href='http://www.google.com/bookmarks/mark?op=edit&amp;output=popup&amp;bkmk=http://www.randomtools.net/php-file-system-cache-58.html&amp;title=PHP File-System Cache' title='Save to Google Bookmarks' onclick='target="_blank";' rel='nofollow'><img src='http://www.randomtools.net/wp-content/plugins/bookmarkify/google.png' style='width:16px; height:16px;' alt='[Google] ' /></a> <a href='http://reddit.com/submit?url=http://www.randomtools.net/php-file-system-cache-58.html&amp;title=PHP File-System Cache' title='Reddit' onclick='target="_blank";' rel='nofollow'><img src='http://www.randomtools.net/wp-content/plugins/bookmarkify/reddit.png' style='width:16px; height:16px;' alt='[Reddit] ' /></a> <a href='http://slashdot.org/bookmark.pl?url=http://www.randomtools.net/php-file-system-cache-58.html&amp;title=PHP File-System Cache' title='Slashdot It!' onclick='target="_blank";' rel='nofollow'><img src='http://www.randomtools.net/wp-content/plugins/bookmarkify/slashdot.png' style='width:16px; height:16px;' alt='[Slashdot] ' /></a> <a href='http://www.stumbleupon.com/submit?url=http://www.randomtools.net/php-file-system-cache-58.html&amp;title=PHP File-System Cache' title='Stumble It!' onclick='target="_blank";' rel='nofollow'><img src='http://www.randomtools.net/wp-content/plugins/bookmarkify/stumbleupon.png' style='width:16px; height:16px;' alt='[StumbleUpon] ' /></a> </div></div>]]></content:encoded>
			<wfw:commentRss>http://www.randomtools.net/php-file-system-cache-58.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

