<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	>
<channel>
	<title>Comments on: J4P5: Javascript For PHP5</title>
	<atom:link href="http://www.sitepoint.com/blogs/2006/01/19/j4p5-javascript-for-php5/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.sitepoint.com/blogs/2006/01/19/j4p5-javascript-for-php5/</link>
	<description>News, opinion, and fresh thinking for web developers and designers. The official podcast of sitepoint.com.</description>
	<pubDate>Tue, 02 Dec 2008 01:36:56 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.5</generator>
		<item>
		<title>By: dandv</title>
		<link>http://www.sitepoint.com/blogs/2006/01/19/j4p5-javascript-for-php5/#comment-807293</link>
		<dc:creator>dandv</dc:creator>
		<pubDate>Fri, 10 Oct 2008 22:32:37 +0000</pubDate>
		<guid isPermaLink="false">http://www.sitepoint.com/blogs/?p=1385#comment-807293</guid>
		<description>I'm looking for the converse:

Does anyone know of a parser &lt;b&gt;for&lt;/b&gt; PHP, written in JavaScript?

I'm trying to add syntax highlight for the &lt;a href="http://marijn.haverbeke.nl/codemirror/" rel="nofollow"&gt;JavaScript source code editor Codemirror&lt;/a&gt; and wouldn't want to reinvent the wheel.</description>
		<content:encoded><![CDATA[<p>I&#8217;m looking for the converse:</p>
<p>Does anyone know of a parser <b>for</b> PHP, written in JavaScript?</p>
<p>I&#8217;m trying to add syntax highlight for the <a href="http://marijn.haverbeke.nl/codemirror/" rel="nofollow">JavaScript source code editor Codemirror</a> and wouldn&#8217;t want to reinvent the wheel.</p>]]></content:encoded>
	</item>
	<item>
		<title>By: Dan Dascalescu</title>
		<link>http://www.sitepoint.com/blogs/2006/01/19/j4p5-javascript-for-php5/#comment-807288</link>
		<dc:creator>Dan Dascalescu</dc:creator>
		<pubDate>Fri, 10 Oct 2008 22:25:16 +0000</pubDate>
		<guid isPermaLink="false">http://www.sitepoint.com/blogs/?p=1385#comment-807288</guid>
		<description>Does anyone know of a parser FOR PHP, written in JavaScript?

I'm not looking for a compiler or interpreter, just a parser to add to enable syntax highlight for the &lt;a href="http://marijn.haverbeke.nl/codemirror/" rel="nofollow"&gt;CodeMirror JavaScript source code editor&lt;/a&gt;.</description>
		<content:encoded><![CDATA[<p>Does anyone know of a parser FOR PHP, written in JavaScript?</p>
<p>I&#8217;m not looking for a compiler or interpreter, just a parser to add to enable syntax highlight for the <a href="http://marijn.haverbeke.nl/codemirror/" rel="nofollow">CodeMirror JavaScript source code editor</a>.</p>]]></content:encoded>
	</item>
	<item>
		<title>By: Tim</title>
		<link>http://www.sitepoint.com/blogs/2006/01/19/j4p5-javascript-for-php5/#comment-719382</link>
		<dc:creator>Tim</dc:creator>
		<pubDate>Fri, 09 May 2008 21:46:48 +0000</pubDate>
		<guid isPermaLink="false">http://www.sitepoint.com/blogs/?p=1385#comment-719382</guid>
		<description>You may find this interesting:
http://web.2point1.com/2008/05/09/full-javascript-parser-for-php/
This JavaScript parser is based in a generic parser framework that produces a full parse tree. No download yet, but there will be eventually.</description>
		<content:encoded><![CDATA[<p>You may find this interesting:<br />
<a href="http://web.2point1.com/2008/05/09/full-javascript-parser-for-php/" rel="nofollow">http://web.2point1.com/2008/05/09/full-javascript-parser-for-php/</a><br />
This JavaScript parser is based in a generic parser framework that produces a full parse tree. No download yet, but there will be eventually.</p>]]></content:encoded>
	</item>
	<item>
		<title>By: peterw8102</title>
		<link>http://www.sitepoint.com/blogs/2006/01/19/j4p5-javascript-for-php5/#comment-114784</link>
		<dc:creator>peterw8102</dc:creator>
		<pubDate>Sun, 03 Dec 2006 09:57:54 +0000</pubDate>
		<guid isPermaLink="false">http://www.sitepoint.com/blogs/?p=1385#comment-114784</guid>
		<description>&lt;blockquote&gt;The &lt;a href="http://www.whitebeam.org/library/guide/TechNotes/form.rhtm" rel="nofollow"&gt;way forms work&lt;/a&gt; [in Whitebeam] is interesting—gives the impression of something vaguely similar to XFORMs.&lt;/blockquote&gt;

Actually the 'forms' model referenced is just an XML/JavaScript library one of us wrote early in whitebeam development and we thought we'd make it available to the wide community. It's not really part of Whitebeam itself - just some contributed code. Whitebeam itself has some calls to get hold of page parameters, headers and other environmental information. The library wraps these in a model. Because Whitebeam lets you write a JavaScript handler for an XML tag - you can build up your own XML syntax for things - which is what this library does. That is you can tell Whitebeam that when it sees a tag called '' it is to run a specified piece of JavaScript.

&lt;a href="http://www.whitebeam.org/library/guide/RedbourneTags/redtags.rhtm?tagname=macrotag" rel="nofollow"&gt;This page&lt;/a&gt; gives an example of writing your own 'searchfor' tag. Again - it's something in Whitebeam that, if you just want ot write lots of procedural JavaScript, you don't use.

Second you also have an additional template language

It's not a different language - the template functionality is all accessed throigh JavaScript calls. 'Template' is a bad name for these - it's a way for us to provide modular, late bound functionality into Whitebeam.</description>
		<content:encoded><![CDATA[<blockquote><p>The <a href="http://www.whitebeam.org/library/guide/TechNotes/form.rhtm" rel="nofollow">way forms work</a> [in Whitebeam] is interesting—gives the impression of something vaguely similar to XFORMs.</p></blockquote>
<p>Actually the &#8216;forms&#8217; model referenced is just an XML/JavaScript library one of us wrote early in whitebeam development and we thought we&#8217;d make it available to the wide community. It&#8217;s not really part of Whitebeam itself - just some contributed code. Whitebeam itself has some calls to get hold of page parameters, headers and other environmental information. The library wraps these in a model. Because Whitebeam lets you write a JavaScript handler for an XML tag - you can build up your own XML syntax for things - which is what this library does. That is you can tell Whitebeam that when it sees a tag called &#8221; it is to run a specified piece of JavaScript.</p>
<p><a href="http://www.whitebeam.org/library/guide/RedbourneTags/redtags.rhtm?tagname=macrotag" rel="nofollow">This page</a> gives an example of writing your own &#8217;searchfor&#8217; tag. Again - it&#8217;s something in Whitebeam that, if you just want ot write lots of procedural JavaScript, you don&#8217;t use.</p>
<p>Second you also have an additional template language</p>
<p>It&#8217;s not a different language - the template functionality is all accessed throigh JavaScript calls. &#8216;Template&#8217; is a bad name for these - it&#8217;s a way for us to provide modular, late bound functionality into Whitebeam.</p>]]></content:encoded>
	</item>
	<item>
		<title>By: peterw8102</title>
		<link>http://www.sitepoint.com/blogs/2006/01/19/j4p5-javascript-for-php5/#comment-114771</link>
		<dc:creator>peterw8102</dc:creator>
		<pubDate>Sun, 03 Dec 2006 09:36:59 +0000</pubDate>
		<guid isPermaLink="false">http://www.sitepoint.com/blogs/?p=1385#comment-114771</guid>
		<description>&lt;blockquote&gt;First you have a much more limited API available to call from Javascript than with PHP. It seems they argue this from the point of view of providing a consistent framework with the ability to scale horizontally built-in “by default”. This seems to go to a pretty extreme level—e.g. they’ve only recently provided an API for file access. That said, if you know what you’re doing, I guess you could add XPCOM to this mix.&lt;/blockquote&gt;

There are actually a few reasons why the API is more limited than that available in PHP - the major one to be honest is that far fewer people have put effort into adding additional APIs.

The 'file' API was indeed added late. Whitebeam is designed to be scalable - meaning that it can run across an array of web-servers with a load-balancer in front. The load-balancer can field page requests to any of the web-servers. If you store information in an operating system 'file' then the next request can go to a different server and the file isn't there. Further, if that server then fails you've lost the data completely. It's generally better to store the file information in a database table which is then accessible by all front-end web servers.  Database replication can then also stop you loosing the data if the database server itself fails.

I think there are very many cases where PHP applications do a fine job until they run out of steam on a single server and have to be re-written to work across an array of servers. By originally not providing things like a local file interface temptation wasn't there to write apps that don't scale.

Even with the file access in place I've never used it for any client applications - I'd basically be shooting myself in the foot.

With respect to templates they are there to make some things simple. Anyone that's tried to write an arbitrarily deep &lt;a href="http://www.whitebeam.org/library/guide/templates/templates/catalogue.rhtm" rel="nofollow"&gt;hierarchical catalogue in SQL knows&lt;/a&gt; it's not easy. Whitebeam lets you do just that and hides all the SQL with some JavaScript calls. 

For those that want to though Whitebeam includes a full PostgreSQL interface, SMTP interface, HTTP interface (for SOAP/XML-RPC etc), and of course file system interface.

At a basic level, if you do want to write everything yourself, &lt;a href="http://www.whitebeam.org/library/guide/overview/phpasp.rhtm" rel="nofollow"&gt;it's very much like PHP but using JavaScript&lt;/a&gt;.</description>
		<content:encoded><![CDATA[<blockquote><p>First you have a much more limited API available to call from Javascript than with PHP. It seems they argue this from the point of view of providing a consistent framework with the ability to scale horizontally built-in “by default”. This seems to go to a pretty extreme level—e.g. they’ve only recently provided an API for file access. That said, if you know what you’re doing, I guess you could add XPCOM to this mix.</p></blockquote>
<p>There are actually a few reasons why the API is more limited than that available in PHP - the major one to be honest is that far fewer people have put effort into adding additional APIs.</p>
<p>The &#8216;file&#8217; API was indeed added late. Whitebeam is designed to be scalable - meaning that it can run across an array of web-servers with a load-balancer in front. The load-balancer can field page requests to any of the web-servers. If you store information in an operating system &#8216;file&#8217; then the next request can go to a different server and the file isn&#8217;t there. Further, if that server then fails you&#8217;ve lost the data completely. It&#8217;s generally better to store the file information in a database table which is then accessible by all front-end web servers.  Database replication can then also stop you loosing the data if the database server itself fails.</p>
<p>I think there are very many cases where PHP applications do a fine job until they run out of steam on a single server and have to be re-written to work across an array of servers. By originally not providing things like a local file interface temptation wasn&#8217;t there to write apps that don&#8217;t scale.</p>
<p>Even with the file access in place I&#8217;ve never used it for any client applications - I&#8217;d basically be shooting myself in the foot.</p>
<p>With respect to templates they are there to make some things simple. Anyone that&#8217;s tried to write an arbitrarily deep <a href="http://www.whitebeam.org/library/guide/templates/templates/catalogue.rhtm" rel="nofollow">hierarchical catalogue in SQL knows</a> it&#8217;s not easy. Whitebeam lets you do just that and hides all the SQL with some JavaScript calls. </p>
<p>For those that want to though Whitebeam includes a full PostgreSQL interface, SMTP interface, HTTP interface (for SOAP/XML-RPC etc), and of course file system interface.</p>
<p>At a basic level, if you do want to write everything yourself, <a href="http://www.whitebeam.org/library/guide/overview/phpasp.rhtm" rel="nofollow">it&#8217;s very much like PHP but using JavaScript</a>.</p>]]></content:encoded>
	</item>
	<item>
		<title>By: peterw8102</title>
		<link>http://www.sitepoint.com/blogs/2006/01/19/j4p5-javascript-for-php5/#comment-114737</link>
		<dc:creator>peterw8102</dc:creator>
		<pubDate>Sun, 03 Dec 2006 09:25:24 +0000</pubDate>
		<guid isPermaLink="false">http://www.sitepoint.com/blogs/?p=1385#comment-114737</guid>
		<description>&lt;blockquote&gt;There’s whitebeam and helma ofcourse, but I they both missed the point. Obviously they come from a java-background, which may explain how they managed to overcomplicate things beyond usability.&lt;/blockquote&gt;

Whitebeam (&lt;a href="http://www.whitebeam.org" rel="nofollow"&gt;http://www.whitebeam.org/about.rhtm&lt;/a&gt;) is *not* from a Java background. I'm not sure which part is over-complicated? Do you mean that it does more than just put SpiderMonkey into an Apache module (which has been said to take a day) and leave the poor programmer to solve all the other problems (session storage, scalability, security, database integration)? Is it overcomplicated because it provides documentation, and so looks like it actually does a lot?</description>
		<content:encoded><![CDATA[<blockquote><p>There’s whitebeam and helma ofcourse, but I they both missed the point. Obviously they come from a java-background, which may explain how they managed to overcomplicate things beyond usability.</p></blockquote>
<p>Whitebeam (<a href="http://www.whitebeam.org" rel="nofollow">http://www.whitebeam.org/about.rhtm</a>) is *not* from a Java background. I&#8217;m not sure which part is over-complicated? Do you mean that it does more than just put SpiderMonkey into an Apache module (which has been said to take a day) and leave the poor programmer to solve all the other problems (session storage, scalability, security, database integration)? Is it overcomplicated because it provides documentation, and so looks like it actually does a lot?</p>]]></content:encoded>
	</item>
	<item>
		<title>By: JdHfcRG1S2</title>
		<link>http://www.sitepoint.com/blogs/2006/01/19/j4p5-javascript-for-php5/#comment-35417</link>
		<dc:creator>JdHfcRG1S2</dc:creator>
		<pubDate>Thu, 06 Jul 2006 01:59:09 +0000</pubDate>
		<guid isPermaLink="false">http://www.sitepoint.com/blogs/?p=1385#comment-35417</guid>
		<description>TkScdxfQaN 5nQ3eY8wCGV GjGfszJX85pTa0</description>
		<content:encoded><![CDATA[<p>TkScdxfQaN 5nQ3eY8wCGV GjGfszJX85pTa0</p>]]></content:encoded>
	</item>
	<item>
		<title>By: 905</title>
		<link>http://www.sitepoint.com/blogs/2006/01/19/j4p5-javascript-for-php5/#comment-30686</link>
		<dc:creator>905</dc:creator>
		<pubDate>Sat, 17 Jun 2006 08:39:40 +0000</pubDate>
		<guid isPermaLink="false">http://www.sitepoint.com/blogs/?p=1385#comment-30686</guid>
		<description>Ӱ޹˾http://www.shuangchuang.com ӣӰӹ˾ƸӰԱϳɳ˫Ӱң˫ӰչӰ籾ƸŮӰԱ
Ӱݺ˫Ӱ˾ӵרҵĵӰ籾Ӿ籾ӰӰ,籾Ӱ˾</description>
		<content:encoded><![CDATA[<p>Ӱ޹˾http://www.shuangchuang.com ӣӰӹ˾ƸӰԱϳɳ˫Ӱң˫ӰչӰ籾ƸŮӰԱ<br />
Ӱݺ˫Ӱ˾ӵרҵĵӰ籾Ӿ籾ӰӰ,籾Ӱ˾</p>]]></content:encoded>
	</item>
	<item>
		<title>By: 563</title>
		<link>http://www.sitepoint.com/blogs/2006/01/19/j4p5-javascript-for-php5/#comment-30494</link>
		<dc:creator>563</dc:creator>
		<pubDate>Fri, 16 Jun 2006 11:05:59 +0000</pubDate>
		<guid isPermaLink="false">http://www.sitepoint.com/blogs/?p=1385#comment-30494</guid>
		<description>˫Ӱ˾ӵרҵĵӰ籾Ӿ籾http://www.shuangchuang.com ӣӰӹ˾ƸӰԱӰݣӰӰ,籾Ӱ˾Ӱ޹˾ϳɳ˫Ӱң˫ӰչӰ籾ƸŮӰԱ</description>
		<content:encoded><![CDATA[<p>˫Ӱ˾ӵרҵĵӰ籾Ӿ籾http://www.shuangchuang.com ӣӰӹ˾ƸӰԱӰݣӰӰ,籾Ӱ˾Ӱ޹˾ϳɳ˫Ӱң˫ӰչӰ籾ƸŮӰԱ</p>]]></content:encoded>
	</item>
	<item>
		<title>By: John S</title>
		<link>http://www.sitepoint.com/blogs/2006/01/19/j4p5-javascript-for-php5/#comment-29861</link>
		<dc:creator>John S</dc:creator>
		<pubDate>Sun, 11 Jun 2006 19:38:28 +0000</pubDate>
		<guid isPermaLink="false">http://www.sitepoint.com/blogs/?p=1385#comment-29861</guid>
		<description>Hi! Very interesting! pwlrdefzp</description>
		<content:encoded><![CDATA[<p>Hi! Very interesting! pwlrdefzp</p>]]></content:encoded>
	</item>
</channel>
</rss>
