<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: Flex and PHP: remoting with SabreAMF</title>
	<atom:link href="http://corlan.org/2009/03/26/flex-and-php-remoting-with-sabreamf/feed/" rel="self" type="application/rss+xml" />
	<link>http://corlan.org/2009/03/26/flex-and-php-remoting-with-sabreamf/?utm_source=rss&amp;utm_medium=rss&amp;utm_campaign=flex-and-php-remoting-with-sabreamf</link>
	<description>Flex, AIR and Rock&#38;Roll</description>
	<lastBuildDate>Thu, 09 Sep 2010 00:42:32 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
	<item>
		<title>By: Babbo Maria</title>
		<link>http://corlan.org/2009/03/26/flex-and-php-remoting-with-sabreamf/comment-page-1/#comment-8481</link>
		<dc:creator>Babbo Maria</dc:creator>
		<pubDate>Wed, 27 Jan 2010 09:34:40 +0000</pubDate>
		<guid isPermaLink="false">http://corlan.org/2009/03/26/flex-and-php-remoting-with-sabreamf/#comment-8481</guid>
		<description>Hey,
Great article (the only one in the world), i discovered php/flex only now  i ever used pear, sabre is a nice solution. Where can i find more documentation about the flex aspect because there are no example about this library. I&#039;d like to build a simple example that non return an array of obj but a simple value (true/false) or an integer is possible with this library or i have to wrap everything in a object.</description>
		<content:encoded><![CDATA[<p>Hey,<br />
Great article (the only one in the world), i discovered php/flex only now  i ever used pear, sabre is a nice solution. Where can i find more documentation about the flex aspect because there are no example about this library. I&#8217;d like to build a simple example that non return an array of obj but a simple value (true/false) or an integer is possible with this library or i have to wrap everything in a object.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Flex and remoting with PHP, which library is the best: Zend AMF, AMFPHP, WebORB for PHP, or SabreAMF? : Mihai CORLAN</title>
		<link>http://corlan.org/2009/03/26/flex-and-php-remoting-with-sabreamf/comment-page-1/#comment-2728</link>
		<dc:creator>Flex and remoting with PHP, which library is the best: Zend AMF, AMFPHP, WebORB for PHP, or SabreAMF? : Mihai CORLAN</dc:creator>
		<pubDate>Tue, 31 Mar 2009 15:02:40 +0000</pubDate>
		<guid isPermaLink="false">http://corlan.org/2009/03/26/flex-and-php-remoting-with-sabreamf/#comment-2728</guid>
		<description>[...] You&#8217;ve decided to go for remoting as the way to communicate with your PHP server, and you&#8217;re wondering which of these four libraries is the best: Zend AMF, AMFPHP, WebORB for PHP, and SabreAMF? [...]</description>
		<content:encoded><![CDATA[<p>[...] You&#8217;ve decided to go for remoting as the way to communicate with your PHP server, and you&#8217;re wondering which of these four libraries is the best: Zend AMF, AMFPHP, WebORB for PHP, and SabreAMF? [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Mihai Corlan</title>
		<link>http://corlan.org/2009/03/26/flex-and-php-remoting-with-sabreamf/comment-page-1/#comment-2714</link>
		<dc:creator>Mihai Corlan</dc:creator>
		<pubDate>Fri, 27 Mar 2009 15:46:50 +0000</pubDate>
		<guid isPermaLink="false">http://corlan.org/2009/03/26/flex-and-php-remoting-with-sabreamf/#comment-2714</guid>
		<description>@mrm

Thanks for your comment.

My intention was to keep the number of lines, especially in the PHP side at a minimum. This blog post is not about how to handle a table in PHP. I assume people are already familiar with this subject. Thus no SQL escaping, no database access layer (Pear DB/ADODB/etc).

But I have to agree with you, it is a bad idea to let in production code that doesn&#039;t protect you of SQL injection.</description>
		<content:encoded><![CDATA[<p>@mrm</p>
<p>Thanks for your comment.</p>
<p>My intention was to keep the number of lines, especially in the PHP side at a minimum. This blog post is not about how to handle a table in PHP. I assume people are already familiar with this subject. Thus no SQL escaping, no database access layer (Pear DB/ADODB/etc).</p>
<p>But I have to agree with you, it is a bad idea to let in production code that doesn&#8217;t protect you of SQL injection.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: mrm</title>
		<link>http://corlan.org/2009/03/26/flex-and-php-remoting-with-sabreamf/comment-page-1/#comment-2708</link>
		<dc:creator>mrm</dc:creator>
		<pubDate>Fri, 27 Mar 2009 10:37:53 +0000</pubDate>
		<guid isPermaLink="false">http://corlan.org/2009/03/26/flex-and-php-remoting-with-sabreamf/#comment-2708</guid>
		<description>65: //add new record
66: $query = &quot;DELETE FROM authors_aut WHERE id_aut = &quot;.$author-&gt;id_aut;
Right...

Also, please use sprintf + mysql_real_escape_string instead of concatenating the query string with the parameters. It&#039;s examples like these that make people oblivious to SQL injection vulnerabilities.

So, instead of 
$query = &quot;UPDATE authors_aut SET fname_aut=&#039;&quot;.$author-&gt;fname_aut.&quot;&#039;, lname_aut=&#039;&quot;.$author-&gt;lname_aut.&quot;&#039; WHERE id_aut=&quot;.  $author-&gt;id_aut;

you can write:
$query = sprintf(&quot;UPDATE authors_aut SET fname_aut=&#039;%s&#039;, lname_aut=&#039;%s&#039; WHERE id_aut=&#039;%s&#039;&quot;, mysql_real_escape_string($author-&gt;fname_aut), mysql_real_escape_string($author-&gt;lname_aut), mysql_real_escape_string($author-&gt;id_aut));

Safer, maintainable and easier to read.</description>
		<content:encoded><![CDATA[<p>65: //add new record<br />
66: $query = &#8220;DELETE FROM authors_aut WHERE id_aut = &#8220;.$author-&gt;id_aut;<br />
Right&#8230;</p>
<p>Also, please use sprintf + mysql_real_escape_string instead of concatenating the query string with the parameters. It&#8217;s examples like these that make people oblivious to SQL injection vulnerabilities.</p>
<p>So, instead of<br />
$query = &#8220;UPDATE authors_aut SET fname_aut=&#8217;&#8221;.$author-&gt;fname_aut.&#8221;&#8216;, lname_aut=&#8217;&#8221;.$author-&gt;lname_aut.&#8221;&#8216; WHERE id_aut=&#8221;.  $author-&gt;id_aut;</p>
<p>you can write:<br />
$query = sprintf(&#8220;UPDATE authors_aut SET fname_aut=&#8217;%s&#8217;, lname_aut=&#8217;%s&#8217; WHERE id_aut=&#8217;%s&#8217;&#8221;, mysql_real_escape_string($author-&gt;fname_aut), mysql_real_escape_string($author-&gt;lname_aut), mysql_real_escape_string($author-&gt;id_aut));</p>
<p>Safer, maintainable and easier to read.</p>
]]></content:encoded>
	</item>
</channel>
</rss>
