<?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>Technologist For Hire &#187; PHP</title>
	<atom:link href="http://www.nexdot.net/blog/tag/php/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.nexdot.net/blog</link>
	<description>An everyday attempt to stand out</description>
	<lastBuildDate>Tue, 09 Feb 2010 20:24:03 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1-alpha-15359</generator>
		<item>
		<title>WinCache, Apache and a pretty graph!</title>
		<link>http://www.nexdot.net/blog/2010/02/09/wincache-apache-and-a-pretty-graph/</link>
		<comments>http://www.nexdot.net/blog/2010/02/09/wincache-apache-and-a-pretty-graph/#comments</comments>
		<pubDate>Tue, 09 Feb 2010 19:57:25 +0000</pubDate>
		<dc:creator>Christian Flickinger</dc:creator>
				<category><![CDATA[PHP]]></category>
		<category><![CDATA[apache]]></category>
		<category><![CDATA[apc]]></category>
		<category><![CDATA[cache]]></category>
		<category><![CDATA[eAccelerator]]></category>
		<category><![CDATA[iis]]></category>
		<category><![CDATA[microsoft]]></category>
		<category><![CDATA[opcode]]></category>
		<category><![CDATA[wincache]]></category>
		<category><![CDATA[windows]]></category>
		<category><![CDATA[xcache]]></category>

		<guid isPermaLink="false">http://www.nexdot.net/blog/?p=146</guid>
		<description><![CDATA[I really wanted to focus this post on WinCache, rather than OpCode Cachers in general &#8211; but it turned into a general post with a star contender. From the Windows Cache extension for PHP website as Microsoft.com: Windows Cache Extension for PHP is a PHP accelerator that is used to increase the speed of PHP [...]]]></description>
			<content:encoded><![CDATA[<p>I really wanted to focus this post on WinCache, rather than OpCode Cachers in general &#8211; but it turned into a general post with a star contender. From the <a href="http://www.iis.net/expand/WinCacheForPhp" target="_blank">Windows Cache extension for PHP website</a> as Microsoft.com:</p>
<blockquote><p>Windows Cache Extension for PHP is a PHP accelerator that is used to increase the speed of PHP applications running on Windows and Windows Server. Once the Windows Cache Extension for PHP is enabled and loaded by the PHP engine, PHP applications can take advantage of the functionality without any code modifications.</p></blockquote>
<p>The documentation makes no mention of Apache, only IIS. I decided to give it a try, and to my amazement, WinCache worked in Apache on Windows. After that I decided to compare the performance of WinCache with the other available options for Windows+Apache.</p>
<p>I referenced the following sites who performed similar tests, but in IIS:</p>
<ul>
<li><a href="http://techportal.ibuildings.com/2009/11/19/php-on-windows-the-wincache-1-0-benchmark/" target="_blank">PHP on Windows: The WinCache 1.0 Benchmark &#8211; ibuildings.com techPortal, Ivo Jansch</a></li>
<li><a href="http://blog.calevans.com/2009/09/06/wincache/" target="_blank">WinCache – Preliminary tests look REALLY good. &#8211; Cal Evans</a></li>
</ul>
<p>You can grab WinCache, and information about it, here:</p>
<ul>
<li><a href="http://www.iis.net/expand/wincacheforphp" target="_blank">Windows Cache extension for PHP</a> website on Microsoft.com</li>
<li><a href="http://pecl.php.net/package/WinCache" target="_blank">The PECL repository page</a> for WinCache</li>
<li><a href="http://ruslany.net/tag/wincache/" target="_blank">Ruslan Yakushev&#8217;s blog posts about WinCache</a> (WinCache Developer)</li>
</ul>
<h2>Testing Environment</h2>
<ul>
<li>Hardware
<ul>
<li>AMD Athlon 64 3800+ (2.50GHz, single core)</li>
<li>2.0GB DDR2</li>
</ul>
</li>
<li>Software
<ul>
<li>Windows Server 2003 w/ SP2</li>
<li>MySQL 5.1.40, locally installed</li>
<li>Apache 2.2.14 vc9</li>
<li>mod_fcgid 2.3.4</li>
<li>php 5.3.1 ts/nts vc9</li>
<li>WordPress 2.9.1 base install (wordpress is a good &#8220;everyman&#8221; product for simulating &#8220;real world&#8221; use, even if its code is ugly)</li>
</ul>
</li>
<li>OpCode Cachers
<ul>
<li>APC 3.1.3.0 (3.1) (NTS)</li>
<li>WinCache 1.0.1117.0 (1.0, stable) (NTS)</li>
<li>XCache 2.0.0-dev(r688) (TS)</li>
<li>eAccelerator 0.9.6rc1 (TS)</li>
</ul>
</li>
</ul>
<h2>Test Method</h2>
<p>To run an unbiased test, I tried to remove as many variables as possible. A batch script was written to perform the following (thus garaunteeing that every test was identical):</p>
<ol>
<li>Stop the apache service</li>
<li>Start the apache service</li>
<li>Run ab (Apache Bench), piping output to a text file</li>
<li>Repeat 1-3 with incremented Concurrency levels (1, 3, 5, 10)</li>
<li>Notify me that all tests have been completed.</li>
</ol>
<p>Aside from testing the relative performance of each opcode cacher, I also wanted to see how well they performaned under differnt levels of &#8220;stress&#8221;, which is why I included Step 4 with different levels of concurrency. After each test-run, I would switch out the opcode cacher in PHP.ini, making sure that the individual opcode cacher settings were &#8220;equal&#8221; in all ways possible (same amount of shared memory, etc etc). After all test-runs were completed I went through the test files that were generated and compared the results in various graphs.</p>
<p>To form a baseline, I also ran the test with no opcode cacher, in both TS (PHP as a module) and NTS (PHP through FastCGI) setups.</p>
<h2>Results</h2>
<p>The results were extremley eye-opening for me. Here is the pretty graph:</p>
<p><img class="alignnone size-full wp-image-152" title="opcode-cacher-graph" src="http://www.nexdot.net/blog/wp-content/uploads/2010/02/opcode-cacher-graph.jpg" alt="" width="583" height="484" /></p>
<p>Let&#8217;s disect this graph a little bit.</p>
<ul>
<li>Not using an OpCode cacher, if able to, is stupid. The performance gain from using ANY of the available OpCode cachers is amazing. For that matter, any form of caching;<strong> If you aren&#8217;t caching ANYTHING, <span style="text-decoration: underline;">you are stupid</span>.</strong></li>
<li>Non-Thread Safe (NTS, FastCGI) PHP performs better than Thread Safe (TS, Module) PHP. Duh.</li>
<li>WinCache works in Apache. This one is obvious from the graph &amp; my tests, but if you were to go read documentation for WinCache it strictly talks about IIS. This is great news for Apache on Windows, because WinCache is made specifically for windows &#8211; unlike the other OpCode cachers which are usually made with Linux in mind and ported to Windows as an afterthought.</li>
<li>XCache&#8217;s performance increased as the &#8220;stress&#8221; increased. All other opcode cachers either performed the same accross the board or decreased in performance as the &#8220;stress&#8221; level increased. It would be interesting to run larger concurrency tests to see where XCache&#8217;s performance falls off at.</li>
<li>WinCache came out as the top performing opcode cacher, on this setup, in this environment, during these tests.</li>
<li>XCache and APC performed exactly opposite of each other as the &#8220;stress&#8221; increased. eAccelerator was practically the &#8220;best fit line&#8221; for XCache and APC, but it did performed slightly better when averaged across concurrency levels.</li>
<li>APC performed almost as well as WinCache at the lowest (none) concurrency level.</li>
</ul>
<h2>What does this all mean?</h2>
<p>It means that in my tests, on Windows, in Apache, using bleeding edge software, I have shown that WinCache is a viable option for Windows development and production servers. I have not shown that WinCache is THE BEST option or the ONLY option; just that <em>is</em> an option &#8212; regardless of what my graphs show. Why? Because <a href="http://www.ibuildings.co.uk/blog/archives/1566-The-Problem-With-Benchmarks.html" target="_blank">benchmarks suck</a> and they only exist to show a relative level of performance as compared to others in an isolated environment. You may have different results. You may need additional features. You may have political/fanboi issues with using one or the other. Will I be using WinCache going forward? Yes, and I will also recommend it to others.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.nexdot.net/blog/2010/02/09/wincache-apache-and-a-pretty-graph/feed/</wfw:commentRss>
		<slash:comments>16</slash:comments>
		</item>
		<item>
		<title>Seven Things</title>
		<link>http://www.nexdot.net/blog/2009/01/16/seven-things/</link>
		<comments>http://www.nexdot.net/blog/2009/01/16/seven-things/#comments</comments>
		<pubDate>Fri, 16 Jan 2009 21:05:09 +0000</pubDate>
		<dc:creator>Christian Flickinger</dc:creator>
				<category><![CDATA[PHP]]></category>
		<category><![CDATA[7 things]]></category>
		<category><![CDATA[apache]]></category>
		<category><![CDATA[seven things]]></category>

		<guid isPermaLink="false">http://www.nexdot.net/blog/?p=81</guid>
		<description><![CDATA[So, according to Michelangelo van Dam&#8217;s helpful &#8220;Who Tagged Who&#8221; tool, I can see that I was &#8220;tagged&#8221; by 4 people in this amazing PHP-Community-based-blog-meme. The rules are simple, and I have waited long enough to fulfill my duties to contribute. Better late than never! 7 Things you may not know about me: I&#8217;ve been [...]]]></description>
			<content:encoded><![CDATA[<p>So, according to <a href="http://www.dragonbe.com">Michelangelo van Dam&#8217;s</a> helpful &#8220;<a href="http://in2it.be/whotaggedwho.php">Who Tagged Who</a>&#8221; tool, I can see that I was &#8220;tagged&#8221; by 4 people in this amazing PHP-Community-based-blog-meme. The rules are simple, and I have waited long enough to fulfill my duties to contribute. Better late than never!</p>
<p>7 Things you may not know about me:</p>
<ol>
<li>I&#8217;ve been working at the same desk job since I was 15 (now 22). I was a hardware technician at first, then became the network engineer/system admin, and am now a systems developer (fancy title for programmer).</li>
<li>I have a slight obsession with <a href="http://flickr.com/photos/spooons/sets/72157612421679516/">collecting</a> and passing out stickers.</li>
<li>My nickname (spoon) originates from a mock stand-up comedy routine I did during a class in Middle School. In the script, someone was insulting me with names of common household items. One of the insults was &#8220;SPOON!&#8221; Ever since then, it just stuck with me. Yes, boring, lame, I know. I used to tell people I was either obsessed with The Tick! or an ex-heroine addict.</li>
<li>I use PHP on windows, exclusively. That isn&#8217;t the shocking part. Are you ready for it? I use PHP, on windows&#8230; with <strong>Apache</strong> &#8211; exclusively. *GASP* Yes, I am one of the few, the proud, the WAMP stack users (in a production environment, no less!!!)</li>
<li>I co-own a few web properties with my Fiance, <a href="http://www.redthreaddiy.com">Katie Soltysiak</a>, which include: <a href="http://www.diyscene.com/forum">DIYscene &#8211; Alternative Craft and Indie Design Forum</a>, <a href="http://www.eburl.net">eBurl &#8211; Short, Trackable eBay URLs</a>, <a href="http://etsy.ownthehour.com">OwnTheHour &#8211; Independent Etsy Promotion</a></li>
<li>I am scared of Linux.</li>
<li>I have a police record in the state of Wisconsin.</li>
</ol>
<p><strong><br />
7 More people to add to this meme.</strong><br />
Now, since I am so late with getting my post written, almost everyone I can personally think of has been tagged. So I will do my best.</p>
<ol>
<li><a href="http://www.mawhorter.net/">Cory Mawhorter</a>: Cory is a past co-worker and friend. He went on to become a professional <a href="http://www.borderhopping.com/">vagabond</a> and created <a href="http://facelift.mawhorter.net/">FLIR (FaceLift Image Replacement) &#8211; an alternative to sIFR</a>.</li>
<li><a href="http://www.tonybibbs.com/">Tony Bibbs</a>: I don&#8217;t know you, but you started this, and have yet to be tagged. TAG *runs*</li>
<li>Jack Bauer</li>
<li>I give up.</li>
<li>-</li>
<li>-</li>
<li>-</li>
</ol>
<p>Ok, so, I failed. Anyways, here are the rules for&#8230; Cory &amp; Jack to follow:</p>
<ul>
<li> Link your original tagger(s), and list these rules on your blog.</li>
<li>Share seven facts about yourself in the post &#8211; some random, some weird.</li>
<li>Tag seven people at the end of your post by leaving their names and the links to their blogs.</li>
<li>Let them know they&#8217;ve been tagged by leaving a comment on their blogs and/or Twitter.</li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://www.nexdot.net/blog/2009/01/16/seven-things/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>Ruby on Fails (story and stickers!)</title>
		<link>http://www.nexdot.net/blog/2008/09/15/ruby-on-fails-story-and-stickers/</link>
		<comments>http://www.nexdot.net/blog/2008/09/15/ruby-on-fails-story-and-stickers/#comments</comments>
		<pubDate>Mon, 15 Sep 2008 17:29:07 +0000</pubDate>
		<dc:creator>Christian Flickinger</dc:creator>
				<category><![CDATA[Conferences]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[elePHPant]]></category>
		<category><![CDATA[ewt08]]></category>
		<category><![CDATA[php|tek]]></category>
		<category><![CDATA[rails]]></category>
		<category><![CDATA[ruby]]></category>
		<category><![CDATA[ruby on fails]]></category>
		<category><![CDATA[ruby on rails]]></category>
		<category><![CDATA[stickerobot]]></category>
		<category><![CDATA[zendcon08]]></category>
		<category><![CDATA[zoltron]]></category>

		<guid isPermaLink="false">http://www.nexdot.net/blog/?p=70</guid>
		<description><![CDATA[So, a week before PHP&#124;TEK 2008 I came up with the genius idea to take the Ruby on Rails logo, and parody it. I wanted to express my views of Ruby on Rails (though never have using RoR) through this modification. I took the logo and simply changed the &#8220;R&#8221; to an &#8220;F&#8221; using a [...]]]></description>
			<content:encoded><![CDATA[<p><img class="alignleft" title="Ruby on Fails" src="http://farm4.static.flickr.com/3248/2851657825_32a87234f2.jpg" alt="" width="270" height="405" />So, a week before PHP|TEK 2008 I came up with the genius idea to take the Ruby on Rails logo, and parody it. I wanted to express my views of Ruby on Rails (though never have using RoR) through this modification.</p>
<p>I took the logo and simply changed the &#8220;R&#8221; to an &#8220;F&#8221; using a font that was almost identical to the original (I used <a href="http://www.whatthefont.com">WhatTheFont</a> to find a similar font).</p>
<p>I took my FAILS logo and made a bunch of <a href="http://www.etsy.com/view_listing.php?listing_id=13567488">buttons/magnets</a> and brought them to PHP|TEK 2008. Apparently they were a bigger hit than I had prepared for, because I ran out of buttons and still had people asking me for them (note: you can purchase a <a href="http://www.etsy.com/view_listing.php?listing_id=13567488">button &amp; magnet set</a> at my etsy shop <a href="http://spooons.etsy.com">http://spooons.etsy.com</a>).</p>
<p>At one of the PHP|TEK 2008 keynotes, <a href="http://terrychay.com/">Terry Chay</a> included (at the last minute) my new FAILS logo in his <strong>The Internet is an Ogre</strong> presentation. I also hear that the logo is still in his presentation, to this day! He properly credited me upon the first use, so I am happy!</p>
<p>Well, for ZendCon 2008, I decided to order a batch of my FAILS logos as a sticker! So I re-created the logo in a high resolution format and got them printed, die-cut (the logo has 2 rounded corners), and shipped before the conference started. They came the DAY BEFORE, and looked AMAZING.</p>
<p>So now I have high-quality vinyl stickers, which plenty of people are enjoying, and I will be adding them to <a href="http://spooons.etsy.com">my etsy shop</a> shortly. They will be $1 each. You can also purchase a sticker, button, magnet set for $2.25.</p>
<p><strong>UPDATE:</strong> Read the comments, including my response. The purpose of &#8220;Ruby on Fails&#8221; is Satire/Parody. It is meant to be funny, for all &#8211; PHP <strong>and</strong> Ruby developers.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.nexdot.net/blog/2008/09/15/ruby-on-fails-story-and-stickers/feed/</wfw:commentRss>
		<slash:comments>21</slash:comments>
		</item>
		<item>
		<title>ZendCon: Zend/PHP Conference and Expo</title>
		<link>http://www.nexdot.net/blog/2007/09/09/zendcon-zendphp-conference-and-expo/</link>
		<comments>http://www.nexdot.net/blog/2007/09/09/zendcon-zendphp-conference-and-expo/#comments</comments>
		<pubDate>Sun, 09 Sep 2007 21:37:52 +0000</pubDate>
		<dc:creator>Christian Flickinger</dc:creator>
				<category><![CDATA[Conferences]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[cali]]></category>
		<category><![CDATA[expo]]></category>
		<category><![CDATA[networking events]]></category>
		<category><![CDATA[zend php]]></category>
		<category><![CDATA[zendcon]]></category>
		<category><![CDATA[zendcon07]]></category>

		<guid isPermaLink="false">http://www.nexdot.net/blog/2007/09/09/zendcon-zendphp-conference-and-expo/</guid>
		<description><![CDATA[On October 7th, 2007 I will be in SF Cali attending the third annual ZendCon Zend/PHP Conference and Expo. I will be in SF Sunday through that Friday. Aside from attending the conference, I am going to hang out in SF and hit up some networking events. It should really fun. I am going to [...]]]></description>
			<content:encoded><![CDATA[<p>On October 7th, 2007 I will be in SF Cali attending the third annual <a href="http://www.zendcon.com">ZendCon</a> Zend/PHP Conference and Expo. I will be in SF Sunday through that Friday. Aside from attending the conference, I am going to hang out in SF and hit up some networking events. It should really fun. I am going to post some of the interesting stuff that I absorb from the conference, so check back in for that.</p>
<p>Also, if you are in SF and wanna hang out, or know of any interesting events/parties I should attend, hit up the About section of the site and grab my email.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.nexdot.net/blog/2007/09/09/zendcon-zendphp-conference-and-expo/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Windows Mobile + Twitter / Facebook = UltraStalk Hack</title>
		<link>http://www.nexdot.net/blog/2007/04/23/windows-mobile-twitter-facebook-ultrastalk-hack/</link>
		<comments>http://www.nexdot.net/blog/2007/04/23/windows-mobile-twitter-facebook-ultrastalk-hack/#comments</comments>
		<pubDate>Mon, 23 Apr 2007 11:46:29 +0000</pubDate>
		<dc:creator>Christian Flickinger</dc:creator>
				<category><![CDATA[Social Media]]></category>
		<category><![CDATA[Twitter]]></category>
		<category><![CDATA[code]]></category>
		<category><![CDATA[Facebook]]></category>
		<category><![CDATA[mortscript]]></category>
		<category><![CDATA[PHP]]></category>

		<guid isPermaLink="false">http://www.nexdot.net/blog/2007/04/23/windows-mobile-twitter-facebook-ultrastalk-hack/</guid>
		<description><![CDATA[Well, I have done it. I have managed to bridge that gap between my computer and my toilet&#8230; or my computer and my drive to work&#8230; or my computer and those boring lectures at school&#8230;. I no longer have to suffer through the pain of not having access to my live feed of everyones life. [...]]]></description>
			<content:encoded><![CDATA[<p>Well, I have done it. I have managed to bridge that gap between my computer and my toilet&#8230; or my computer and my drive to work&#8230; or my computer and those boring lectures at school&#8230;. I no longer have to suffer through the pain of not having access to my live feed of everyones life. I can now continue my daily stalk even when I am not at my computer.</p>
<p>If you are like me, you have your Facebook status update feed for all of your friends in your favorite feed reader and set it to update every 1 minute. You also added your friend&#8217;s Twitter feeds. You may have even taken advantage of Facebooks SMS notification feature, where it txt-msgs you whenever a friend updates their status&#8230; Well, that was not good enough for me, and only provided me with limited info on a few people&#8230; I wanted INSTANT access to my Facebook/Twitter stalking resources!</p>
<p>So, I found a way. I own a Motorola Q, and I love it. Despite all of the problems everyone has with it and what everyone says, I find it to be the most useful mobile tool I have. I watch TV on it (SlingBox + Comcast Digital Cable), listen to music on it (SiriusWM5 for Sirius, and Orb for mp3s from my large library on my desktop PC), play SNES games on it (thank you PocketNesterPlus), use it for GPS navigation &amp; phone book (Windows Live Search), instant message from it (Agile Messenger), and of course that phone/email/web thing as well. <strong>I WANTED MORE!</strong></p>
<p>I wanted to move my obsessive Facebook/Twitter habits into my mobile lifestyle so I could stalk on the go. Here is my solution:</p>
<p style="text-align: center"><img src="http://s78733.gridserver.com/blog/wp-content/uploads/2007/04/ss000.jpg" alt="ss000.jpg" /></p>
<p>Notice the information that I circled in red. This the latest Facebook update from my entire set of friends. &#8220;Katie S. is on her way to target.&#8221; My homescreen is updated every <strong>3 minutes</strong> with the latest status update from Facebook. Whenever someone updates their status, my phone makes a very light noise and the update is displayed on my home screen. <em><strong>ULTRASTALK!</strong></em> I see all and hear all now.</p>
<p>And now, here is how it works. I found a scripting language that works on mobile phones and has a nice set of functions and features. It is called <a href="http://www.sto-helit.de/index.php?module=page&amp;entry=ms_overview&amp;action=view" title="MortScript" target="_blank">MortScript</a>. MortScript has the ability to read/write to the registry, download and read files from the internet, automatically run at specified intervals, etc etc etc&#8230; I created a very simple script that checks a PHP file on a server of mine, and saves the information to the phone. Then I added a built-in plugin to the home screen that displays that information. I currently only have it doing a live Facebook status update, but the PHP script could easily be made to pull Twitter, or even BOTH. This MortSCript is only for displaying the information, so really, the PHP script could grab ANY type of information, such as: server status, new email, feed updates (such as facebook/twitter), IM presence information, number of users on your website, new comments on your blog, important alerts (like a pager?). Really, I have created the framework for any type of instant mobile alerts.</p>
<p>MortScript:</p>
<pre lang="VB">
scriptURL = "URL_TO_YOUR_SCRIPT"
ThisScriptPath = SystemPath("ScriptPath")
ThisScriptName = SystemPath("ScriptName") &#038; SystemPath("ScriptExt")

#Update interval in seconds, 180 = 3 minutes.
UpdateInterval = 180

Call SetUpdateTime

#Turn Errors OFF
ErrorLevel("off")

Contents = ""
wURL = scriptURL
Contents = ReadFile(wURL)
OldContents = RegRead ("HKCU","ControlPanelOwner","Notes")

If (OldContents ne Contents)
	#For the Q
	RegWriteString ("HKCU","ControlPanelOwner","Notes", Contents)

	#Uncomment the following and change filename to play a sound
	#PlaySound("NewUpdate.wav")
EndIf

Exit
# -------------------------------------------------------------
Sub SetUpdateTime
If (UpdateInterval <> 0)
	RunAtTime = TimeStamp() + (UpdateInterval)

	#Remove the Notification Queue (if exists)
	RemoveNotifications(ThisScriptPath &#038; "\" &#038; ThisScriptName)

	#Set the Notification Queue Item
	RunAt(RunAtTime, ThisScriptPath &#038; "\" &#038; ThisScriptName)
EndIf
EndSub</pre>
<p>PHP Script</p>
<pre lang="PHP">
$url = 'FACEBOOK_STATUS_FEED_URL';
$ch = curl_init($url);
curl_setopt($ch, CURLOPT_HEADER, 0);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($ch, CURLOPT_USERAGENT, "Mozilla/5.0");
$xml = curl_exec($ch);
curl_close($ch);

$xmlobj = simplexml_load_string($xml);
$status = $xmlobj->channel->item[0]->title;
$author = $xmlobj->channel->item[0]->author;
$authorn = split(' ',$author);

switch(count($authorn)):
case 1: // single name
    $authorabbr = $authorn[0];
    break;
case 2: // first &amp; last name
    $authorabbr = $authorn[0].' '.$authorn[1]{0}.'.';
    break;
case 3: // first middle last, take first and last
case 4: // first middle last sr/jr/III, take first and last
    $authorabbr = $authorn[0].' '.$authorn[2]{0}.'.';
    break;
default:
    $authorabbr = 'Someone';
    break;
endswitch;

$status = str_replace($author, ucwords($authorabbr), $status);

echo $status;
?></pre>
<p>XML to add to your home screen file:</p>
<pre lang="XML">
<plugin clsid="{4824B576-EFFE-45cf-BAE9-649B930CD244}" height="23">
	<background b-border-width="0"></background>
	<label halign="left" h="20" x="38" y="0" w="275" font-size="15" padding-right="0">
		<text><notes></notes>
       	</text></label>
</plugin></pre>
<p>You will obviously need to customize the XML to suite your current home screen needs (x,y,height,width,font-size, etc etc). Follow <a href="http://www.sto-helit.de/index.php?module=page&amp;entry=ms_overview&amp;action=view" title="MortScript" target="_blank">this link to download MortScript</a> and install it. Name the script above ultrastalk.mscr and run it from filemanager to start it.<strong> If anyone is actually interested in using this, just leave a comment and I will post a follow up with step-by-step instructions.</strong></p>
]]></content:encoded>
			<wfw:commentRss>http://www.nexdot.net/blog/2007/04/23/windows-mobile-twitter-facebook-ultrastalk-hack/feed/</wfw:commentRss>
		<slash:comments>9</slash:comments>
		</item>
		<item>
		<title>Updating Facebook status using PHP</title>
		<link>http://www.nexdot.net/blog/2007/04/20/updating-facebook-status-using-php/</link>
		<comments>http://www.nexdot.net/blog/2007/04/20/updating-facebook-status-using-php/#comments</comments>
		<pubDate>Fri, 20 Apr 2007 17:35:36 +0000</pubDate>
		<dc:creator>Christian Flickinger</dc:creator>
				<category><![CDATA[Facebook]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[Social Media]]></category>
		<category><![CDATA[api]]></category>
		<category><![CDATA[code]]></category>
		<category><![CDATA[idea]]></category>
		<category><![CDATA[mobile service]]></category>
		<category><![CDATA[status updates]]></category>
		<category><![CDATA[statuses]]></category>
		<category><![CDATA[Twitter]]></category>

		<guid isPermaLink="false">http://www.nexdot.net/blog/2007/04/20/updating-facebook-status-using-php/</guid>
		<description><![CDATA[I use Facebook as my 'social network of choice', and the means for updating friends of my status. The main reason is because most of my friends have no idea what Twitter is, nor would many of them use it. Everyone I know does have a Facebook account though, so it seems only natural that I use the medium which will give my updates the largest audience.

Although I do not use Twitter, I fully support it and love the idea of it.

Out of curiosity, I wanted to see if I could meld Facebook and Twitter. What I envisioned was a one-stop shop for updating my statuses across the internet.]]></description>
			<content:encoded><![CDATA[<blockquote style="border: 1px dotted #ccc; padding: 2px;"><p>
<strong>[<em>UPDATE</em>: October 01, 2007 @ 11:09am EST]</strong><br />
Facebook has <a href="http://www.nexdot.net/blog/2007/10/01/told-ya-so-facebook-adds-userssetstatus-api-method/">officially implemented</a> a users.setStatus() method in their API. <a href="http://www.nexdot.net/blog/2007/10/01/told-ya-so-facebook-adds-userssetstatus-api-method/">Read more&#8230;</a></p>
<p><strong>[<em>UPDATE</em>: September 04, 2007 @ 7:21pm EST]</strong><br />
It is with great disappointment that I must make this announcement. Facebook has requested that I remove the code from my website. They have also contacted everyone else who has found my code and publicly mentioned that they are using it. I originally did not comply, but my Facebook account was disabled and legal action was about to be pursued.</p>
<p>I am saddened at this turn of events because the idea behind the code was to extend Facebook&#8217;s current service and fill in the gap that their API had. The API still does not provide a means for updating ones status.</p>
<p>To everyone who found my code useful, everyone who ported my code to various other languages, those who integrated my code into their projects, and those who believe in <a href="http://adrianspender.com/blog/2007/05/21/federated-status/" title="Drive Through...: Federated Status">Federated Status</a>, Thank You.</p>
<p>- Christian Flickinger
</p></blockquote>
<p>I use Facebook as my &#8216;social network of choice&#8217;, and the means for updating friends of my status. The main reason is because most of my friends have no idea what Twitter is, nor would many of them use it. Everyone I know does have a Facebook account though, so it seems only natural that I use the medium which will give my updates the largest audience.</p>
<p>Although I do not use Twitter, I fully support it and love the idea of it.</p>
<p>Out of curiosity, I wanted to see if I could meld Facebook and Twitter. What I envisioned was a one-stop shop for updating my statuses across the internet. To do this you would need something that can PUSH and ACCEPT updates. Twitter has an API that will ACCEPT updates, but nothing that will PUSH them. Facebook has an API that does not have any functions for status updates at all, but they do have status update RSS feeds. I want Twitter to be the top of my update tree. I want to update twitter (because of its SMS/Web/IM/API updating capabilities) and have everything else know about it. The API allows me to make a plugin for my IM client that could possibly throw my latest away message up on Twitter. SMS/Web/IM allow me to update twitter from wherever I am.</p>
<p>The problem with Facebook: You can only PULL status updates, and until now, you can not UPDATE them programaticaly. Searching google I quickly find <a href="http://www.designmeme.com/2007/03/22/twitterbook/" title="Twitterbook">a way to manually post my Facebook status to Twitter</a> and a post that <a href="http://www.srhaber.com/2007/04/02/twitter-and-facebook-status/" title="Shaun Haber: Twitter and Facebook Status" target="_blank">lays out the possibilities for facebook-twitter integration</a>.</p>
<p>Well, I do not give up that easy. I want a way to update Facebook without physically logging into Facebook. It can be done, and I found out how. Facebook has no status update API and their update box uses AJAX to post, so cURL is out of question&#8230; or so everyone thought! Facebook has a mobile service (<a href="http://m.facebook.com" title="Facebook Mobile" target="_blank">http://m.facebook.com</a>) that allows you to update your status and view your Facebook from a cellphone.  It looks the best on Windows Mobile devices (I have a Q), and works great on normal WAP browsers. This is the key to my facebook-twitter hack.</p>
<p>Facebook mobile uses a normal POST method for updating status. How cool is that? This means that it HAS to be possible to update your Facebook from a program. Using nothing but cURL (or, in my case, PHP with the cURL extension), you can update your Facebook status. What does this mean? This means that if someone wanted, they could easily keep their Facebook status synced up with their latest Twitter status. The code is below. Feel free to use it. Mentioning my blog/name would be greatly appreciated.</p>
<pre lang="php">
// Code removed at request of Facebook</pre>
<p>I have already created my first test mashup of Winamp &amp; Facebook, successfully displaying, in real time, the current song I was listening to in Winamp as my Facebook status. Anyone with some experience could easily use the above code to check Twitter and (if updated) push to Facebook. Happy mashing!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.nexdot.net/blog/2007/04/20/updating-facebook-status-using-php/feed/</wfw:commentRss>
		<slash:comments>64</slash:comments>
		</item>
	</channel>
</rss>
