<?xml version="1.0"?>
<rss version="2.0">
  <channel>
    <title>PHPDeveloper.org</title>
    <link>http://www.phpdeveloper.org</link>
    <description>Up-to-the Minute PHP News, views and community</description>
    <language>en-us</language>
    <pubDate>Wed, 19 Jun 2013 21:31:39 -0500</pubDate>
    <ttl>30</ttl>
    <item>
      <title><![CDATA[James Morris: A WebSockets, Ratchet, Silex and Redis PubSub Implementation]]></title>
      <guid>http://www.phpdeveloper.org/news/19080</guid>
      <link>http://www.phpdeveloper.org/news/19080</link>
      <description><![CDATA[<p>
<i>James Morris</i> has an <a href="http://blog.jmoz.co.uk/websockets-ratchet-react-redis">interesting new post</a> to his site about the creation of a real-time web service that could be used for iOS applications via Websockets. He chose <a href="http://socketo.me/">Ratchet</a> for the handling (a PHP-based websocket tool) combined with Redis and Silex.
</p>
<blockquote>
I was approached by a betting/gambling development company who potentially needed a middleware building that would pull from an existing gambling web service and basically transmit to connected iPhone clients the changes from the web service. At first, the obvious answer might be to create another REST web service that the iPhone clients could just ping for changes. However, one of the devs explained that this wouldn't be fast enough, or scale - they'd need changes to be transmitted as soon as possible, as the app would be a real-time betting app and there'd be thousands of connections to the server.
</blockquote>
<p>
His solution involved hooking together Ratchet, Redis, Silex and Predis-async to create <a href="http://silex-test.jmoz.co.uk/pubsub">this sample tool</a> for handling the websocket requests. it uses the "pubsub" mechanism of Redis to push the updates out to listening clients.
</p>]]></description>
      <pubDate>Wed, 23 Jan 2013 12:09:33 -0600</pubDate>
    </item>
    <item>
      <title><![CDATA[NetTuts.com: Getting Real-Time with Pusher]]></title>
      <guid>http://www.phpdeveloper.org/news/16949</guid>
      <link>http://www.phpdeveloper.org/news/16949</link>
      <description><![CDATA[<p>
On NetTuts.com today there's a new tutorial showing you how to <a href="http://net.tutsplus.com/tutorials/javascript-ajax/getting-real-time-with-pusher/">implement the Pusher service</a> that gives you <a href="http://pusher.com/">real-time messaging</a> for your application. Their backend for the project is written in PHP using Pusher's library.
</p>
<blockquote>
Do you want to spice up your web applications by making them real-time - but don't want to create new infrastructures for the sole purpose of getting web sockets to work? In this article, we'll explore how to use and implement <a href="http://pusher.com/">Pusher</a>, an HTML5 WebSocket-powered real-time messaging service for your applications.
</blockquote>
<p>
Pusher uses HTML5 <a href="http://en.wikipedia.org/wiki/WebSocket">WebSockets</a> to handle the messaging, so you'll need a browser that supports it to follow along with the tutorial. The Pusher API provides and endpoint for authorization and the push and pull of messages. In the tutorial, they create a simple chat application that gives a "Who's Online" and a window with the latest messages. You can download the full source (Javascript and PHP) <a href="http://nettuts.s3.amazonaws.com/1059_pusher/demo.zip">here</a> or view a demo <a href="http://nikkobautista.com/demos/pusher">here</a>.
</p>]]></description>
      <pubDate>Wed, 05 Oct 2011 08:39:52 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[Gonzalo Ayuso's Blog: Real time monitoring PHP applications with websockets and node.js]]></title>
      <guid>http://www.phpdeveloper.org/news/16313</guid>
      <link>http://www.phpdeveloper.org/news/16313</link>
      <description><![CDATA[<p>
<i>Gonzalo Ayuso</i> has a new post to his blog today looking at a method you can use for <a href="http://gonzalo123.wordpress.com/2011/05/09/real-time-monitoring-php-applications-with-websockets-and-node-js/">real-time monitoring of your PHP applications</a> with a combination of websockets and Node.js. The trick is to handle the PHP errors and send them over to a Node.js server for processing.
</p>
<blockquote>
The inspection of the error logs is a common way to detect errors and bugs. We also can show errors on-screen within our developement server, or we even can use great tools like firePHP to show our PHP errors and warnings inside our firebug console. That's cool, but we only can see our session errors/warnings. If we want to see another's errors we need to inspect the error log. tail -f is our friend, but we need to surf against all the warnings of all sessions to see our desired ones. Because of that I want to build a tool to monitor my PHP applications in real-time.
</blockquote>
<p>
The service will work similar to a chat server, sending messages one at a time to the remote server via a web client (HTML5-based) and some backend PHP. He includes all the code you'll need to create the HTTP and web socket server as well as the web client (with some Javascript) and some example server-side PHP. It throws an exception and catches it to send to the waiting Node.js server. A <a href="http://www.youtube.com/watch?v=KnBRcU_tBkk">screencast</a> is also included showing the full process. You can get the complete code for this example in <a href="https://github.com/gonzalo123/RealTimeMonitor">this repository</a> on <i>Gonzalo</i>'s github account.
</p>]]></description>
      <pubDate>Mon, 09 May 2011 11:02:28 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[Gonzalo Ayuso's Blog: Real time notifications with PHP]]></title>
      <guid>http://www.phpdeveloper.org/news/16051</guid>
      <link>http://www.phpdeveloper.org/news/16051</link>
      <description><![CDATA[<p>
In a new post <i>Gonzalo Ayuso</i> about a system he's developed to create <a href="http://gonzalo123.wordpress.com/2011/03/14/real-time-notifications-with-php/">real-time notifications</a> for PHP applications using a mix of PHP and javascript (jQuery).
</p>
<blockquote>
Real time communications are cool, isn't it? Something impossible to do five years ago now (or almost impossible) is already available. Nowadays we have two possible solutions. WebSockets and Comet. [...] I prefer to use comet (at least now). It's not as good as websockets but pretty straightforward ant it works (even on IE). Now I'm going to explain a little script that I've got to perform a comet communications, made with PHP. 
</blockquote>
<p>
His little sample application detects when a user has clicked on a link by subscribing to an event and using the javascript callback to send the message of a click event and wait for a response. You can find the complete code for the example <a href="https://github.com/gonzalo123/nov-comet">over on github</a>.
</p>]]></description>
      <pubDate>Wed, 16 Mar 2011 08:46:23 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[Michael Feichtinger's Blog: PHP5 WebSocket Example - A Simple Chat]]></title>
      <guid>http://www.phpdeveloper.org/news/15850</guid>
      <link>http://www.phpdeveloper.org/news/15850</link>
      <description><![CDATA[<p>
<i>Michael Feichtinger</i> has posted <a href="http://bohuco.net/blog/2011/01/php5-websocket-example-a-simple-chat/">a simple websocket example</a> to his blog today. It shows the creation of a simple "web chat" application for real-time communication without the mess that can come with ajax.
</p>
<blockquote>
The classic example for websockets is a chat. This chat example has only 200 lines of code (excl. the Websocket class), is really easy to understand and customizable.
</blockquote>
<p>
He creates a basic "WebsocketClass" class that (in his example) connects to an IP and port. It uses JSON as the messaging format and some basic javascript to handle the clicks of the "chat" and "login" buttons. You can see an example in action <a href="http://bohuco.net/labs/php-websocket-chat/">here</a> and download the source for the <a href="http://bohuco.net/labs/php-websocket-chat/?source=server.php">server.php here</a>.
</p>]]></description>
      <pubDate>Thu, 03 Feb 2011 09:47:28 -0600</pubDate>
    </item>
    <item>
      <title><![CDATA[Justin Ireland's Blog: Real-Time Embedded User Interfaces Using HTML/CSS/js and Websockets]]></title>
      <guid>http://www.phpdeveloper.org/news/14966</guid>
      <link>http://www.phpdeveloper.org/news/14966</link>
      <description><![CDATA[<p>
<i>Justin Ireland</i> has <a href="http://justinireland.com/real-time-embedded-user-interfaces-using-html-css-js-and-websockets/">posted an article</a> to his blog about creating real-time interfaces for your sites using the combination of HTML, CSS and Javascript to connect to a physical interface on the backend.
</p>
<blockquote>
Physical interfaces such as button panels or remote controls have many disadvantages. Panel controls require a dedicated display for feedback and physical access to a fixed location. IR remote controls offer only one-way communication with limited feedback and can become difficult to manage for multiple devices. [...] We propose a new type of solution to address these issues and bring simplified management and control to a broader market through embedded virtual interfaces.
</blockquote>
<p>
He lays out <a href="http://justinireland.com/wp-content/uploads/2010/08/Real-TimeEmbeddedVirtualUserInterfaces2.png">the structure of the application</a>, some of the issues that could come up in the connection (using <a href="http://en.wikipedia.org/wiki/Comet_(programming)">COMET</a> and <a href="http://en.wikipedia.org/wiki/Websockets">Websockets</a>). His <a href="http://justinireland.com/real-time-embedded-user-interfaces-using-html-css-js-and-websockets/3/">proof of concept</a> is a connection to <a href="http://www.hallresearch.com/page/Products/SW-HDMI-4">a HDMI switch</a> that can be talked to through an <a href="http://www.lantronix.com/device-networking/embedded-device-servers/matchport-ar.html">embedded controller</a> via a <a href="http://justinireland.com/wp-content/uploads/2010/08/SW-HDMI-4-demo.jpg">simple interface</a>.
</p>]]></description>
      <pubDate>Mon, 16 Aug 2010 13:17:41 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[Sony AK Knowledge Center: Create Realtime Chart Without Page Refresh using FusionCharts Free & Ajax]]></title>
      <guid>http://www.phpdeveloper.org/news/14124</guid>
      <link>http://www.phpdeveloper.org/news/14124</link>
      <description><![CDATA[<p>
On the Sony AK Knowledge Center there's a new tutorial showing how to use FusionCharts (Free) <a href="http://www.sony-ak.com/2010/02/create-realtime-chart-without-page-refresh-using-fusioncharts-free-and-ajax-prototype-js/">to create a real-time charts with no page refresh</a>. <a href="http://www.fusioncharts.com/free/">FusionCharts</a> is an open source Flash charting component for desktop and web apps.
</p>
<blockquote>
We will create realtime chart data update that reflect to price fluctuation. There is a line type chart to visualize the price fluctuation. The data of price fluctuation will be fetched from database every 5 seconds using Ajax call and then display the latest 5 (five) data to the chart without any page refresh.
</blockquote>
<p>
Using FusionCharts and <a href="http://api.prototypejs.org/">Prototype</a>, they show how to pull information out of a backend MySQL database into a basic graph (HTML and Javascript provided) with a periodic update that grabs the latest from the backend PHP script and pushes it to the graph. You can see an <a href="http://www.sony-ak.com/wp-content/uploads/2010/02/price_fluctuation_with_fusioncharts_free.jpg">example of the graph here</a>.
</p>]]></description>
      <pubDate>Wed, 03 Mar 2010 13:36:55 -0600</pubDate>
    </item>
    <item>
      <title><![CDATA[Northclick Blog: Getting the PHP fatal errors]]></title>
      <guid>http://www.phpdeveloper.org/news/7843</guid>
      <link>http://www.phpdeveloper.org/news/7843</link>
      <description><![CDATA[<p>
From the Nothclick dev blog, there's <a href="http://blog.northclick.de/archives/17">this new post</a> from <i> Soenke Ruempler</i> that talks about working with error messages in PHP, specifically with fatal errors.
</p>
<blockquote>
One big issue of the PHP error handling is that there's no built-in way to catch fatal errors with an user-defined error handler. So I thought a little bit about it and maybe you have better approaches or solutions...
</blockquote>
<p>
With the goal of emailing the developers when such an error is thrown, he comes up with three different "storage methods" - using syslog, sapi, or a common logfile - and two different methods for watching them - file watching and syslogger. He works through these two options, trying to figure out which out be the simplest to implement.
</p>
<p>
He comes to the conclusion, though, that he might just be better off with one of the packages already out there to do something similar. Of the four he found, <a href="http://sourceforge.net/projects/swatch/">Swatch</a> seemed to fit the best. He includes configuration and setup info to illustrate.
</p>]]></description>
      <pubDate>Tue, 15 May 2007 07:49:00 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[Joshua Eichorn's Blog: Adding AJAX to a Website step by step, Part II]]></title>
      <guid>http://www.phpdeveloper.org/news/6000</guid>
      <link>http://www.phpdeveloper.org/news/6000</link>
      <description><![CDATA[<p>
Taking the next step in the series, <i>Joshua Eichorn</i> has posted <a href="http://blog.joshuaeichorn.com/archives/2006/08/10/adding-ajax-to-a-website-step-by-step-part-ii/">part two</a> of the "Adding Ajax to a Website step by step" series today, a continuation from <a href="http://www.phpdeveloper.org/news/5981">this previous post</a>.
</p>
<blockquote>
<p>
I have a lot more change's i'd like to make to webthumb so the last article (Adding AJAX to a website step by step) is now the start of the series. In this article will be taking front page of webthumb and making it live. The the stats and recent thumbnails will update in real time, making for a nice slick presentation.
</p>
<p>
I hope to release and article for each improvement I make to webthumb, giving everyone idea of whats involved in AJAXing a real website. But a series of articles won't cover everything you want to know about AJAX.
</p>
</blockquote>
<p>
The focus in <a href="http://blog.joshuaeichorn.com/archives/2006/08/10/adding-ajax-to-a-website-step-by-step-part-ii/">this new post</a> is his method of grabbing the latest information from the server without a needless page reload. In this case, that means grabbing the latest thumbnails that have been created.
</p>
<p>
He includes the code for the different parts: exporting the PHP class to allow the Javascript to access it, a sample response from the HTML_AJAX server and the server code itself. From there, it's back to the client side for the Javascript code to make the request (and set a timer on it) and updating the page with the latest content. There's also a brief mention of how HTML_AJAX can push out other Javascript libraries, which he uses to push <a href="http://moofx.mad4milk.net/">moo.fx</a> for a transition effect on the thumbnails.
</p>]]></description>
      <pubDate>Thu, 10 Aug 2006 07:57:28 -0500</pubDate>
    </item>
  </channel>
</rss>
