<?xml version="1.0" encoding="UTF-8"?><!-- generator="wordpress/2.1.3" -->
<rss version="2.0" 
	xmlns:content="http://purl.org/rss/1.0/modules/content/">
<channel>
	<title>Comments on: Zend Framework Zend_Db - When to Quote and When Not to Quote User Input</title>
	<link>http://www.eatmybusiness.com/food/2007/08/05/zend-framework-zend_db-when-to-quote-and-when-not-to-quote-user-input/34/</link>
	<description>Web Publishing Techniques</description>
	<pubDate>Tue, 07 Feb 2012 21:10:24 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.1.3</generator>

	<item>
		<title>By: infoseeker</title>
		<link>http://www.eatmybusiness.com/food/2007/08/05/zend-framework-zend_db-when-to-quote-and-when-not-to-quote-user-input/34/#comment-17988</link>
		<author>infoseeker</author>
		<pubDate>Fri, 23 Apr 2010 02:28:47 +0000</pubDate>
		<guid>http://www.eatmybusiness.com/food/2007/08/05/zend-framework-zend_db-when-to-quote-and-when-not-to-quote-user-input/34/#comment-17988</guid>
					<description>Here is an answer from the horse's mouth:

http://stackoverflow.com/questions/975009/avoiding-mysql-injections-with-the-zend-db-class/985316#985316</description>
		<content:encoded><![CDATA[<p>Here is an answer from the horse&#8217;s mouth:</p>
<p><a href="http://stackoverflow.com/questions/975009/avoiding-mysql-injections-with-the-zend-db-class/985316#985316" rel="nofollow">http://stackoverflow.com/questions/975009/avoiding-mysql-injections-with-the-zend-db-class/985316#985316</a></p>
]]></content:encoded>
				</item>
	<item>
		<title>By: Cristian</title>
		<link>http://www.eatmybusiness.com/food/2007/08/05/zend-framework-zend_db-when-to-quote-and-when-not-to-quote-user-input/34/#comment-18777</link>
		<author>Cristian</author>
		<pubDate>Tue, 07 Dec 2010 12:58:00 +0000</pubDate>
		<guid>http://www.eatmybusiness.com/food/2007/08/05/zend-framework-zend_db-when-to-quote-and-when-not-to-quote-user-input/34/#comment-18777</guid>
					<description>Whe you make a select try to not do thinks like this:
$this-&#62;db-&#62;updatet('table',array('row1' =&#62; 'data1','row2'=&#62;'data2'),'id = '.$id);

use quoteInto. Ex:

$this-&#62;db-&#62;updatet('table',array('row1' =&#62; 'data1','row2'=&#62;'data2'),$this-&#62;db-&#62;quoteInto('id = ', $id));</description>
		<content:encoded><![CDATA[<p>Whe you make a select try to not do thinks like this:<br />
$this-&gt;db-&gt;updatet(&#8217;table&#8217;,array(&#8217;row1&#8242; =&gt; &#8216;data1&#8242;,&#8217;row2&#8242;=&gt;&#8217;data2&#8242;),&#8217;id = &#8216;.$id);</p>
<p>use quoteInto. Ex:</p>
<p>$this-&gt;db-&gt;updatet(&#8217;table&#8217;,array(&#8217;row1&#8242; =&gt; &#8216;data1&#8242;,&#8217;row2&#8242;=&gt;&#8217;data2&#8242;),$this-&gt;db-&gt;quoteInto(&#8217;id = &#8216;, $id));</p>
]]></content:encoded>
				</item>
	<item>
		<title>By: sonam</title>
		<link>http://www.eatmybusiness.com/food/2007/08/05/zend-framework-zend_db-when-to-quote-and-when-not-to-quote-user-input/34/#comment-19477</link>
		<author>sonam</author>
		<pubDate>Sat, 05 Nov 2011 09:20:16 +0000</pubDate>
		<guid>http://www.eatmybusiness.com/food/2007/08/05/zend-framework-zend_db-when-to-quote-and-when-not-to-quote-user-input/34/#comment-19477</guid>
					<description>In Zend there are inbuilt $this-&#62;db-&#62;quoteInto() function, this function are used to remove 
The following characters(i.e. magical characters):

\x00 �
\n
\r
\
'
"
\x1a =


if  you want to insert the form input in to database ,then  you must use the "quote", because it act as a sql anti injection, it prevent  your site from hacking.....
One of the best example is your login form:

in login from there are query like:

select * from user_info where username="sonam" and password="sonam";

so,

in the login page : if the user wrote:

username: "sonam=1  or 1=1 
then the you can loged in with out password,

so use $this-&#62;db-&#62;quoteInto()  function  similar to as my brother Cristian Says</description>
		<content:encoded><![CDATA[<p>In Zend there are inbuilt $this-&gt;db-&gt;quoteInto() function, this function are used to remove<br />
The following characters(i.e. magical characters):</p>
<p>\x00 �<br />
\n<br />
\r<br />
\<br />
&#8216;<br />
&#8221;<br />
\x1a =</p>
<p>if  you want to insert the form input in to database ,then  you must use the &#8220;quote&#8221;, because it act as a sql anti injection, it prevent  your site from hacking&#8230;..<br />
One of the best example is your login form:</p>
<p>in login from there are query like:</p>
<p>select * from user_info where username=&#8221;sonam&#8221; and password=&#8221;sonam&#8221;;</p>
<p>so,</p>
<p>in the login page : if the user wrote:</p>
<p>username: &#8220;sonam=1  or 1=1<br />
then the you can loged in with out password,</p>
<p>so use $this-&gt;db-&gt;quoteInto()  function  similar to as my brother Cristian Says</p>
]]></content:encoded>
				</item>
</channel>
</rss>

