<?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: Simple MySQL Search Query</title>
	<atom:link href="http://www.v-nessa.net/2007/07/04/simple-mysql-search-query/feed" rel="self" type="application/rss+xml" />
	<link>http://www.v-nessa.net/2007/07/04/simple-mysql-search-query</link>
	<description>pink is the new black</description>
	<lastBuildDate>Thu, 26 Jan 2012 17:17:54 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
	<item>
		<title>By: Jacob</title>
		<link>http://www.v-nessa.net/2007/07/04/simple-mysql-search-query/comment-page-1#comment-11067</link>
		<dc:creator>Jacob</dc:creator>
		<pubDate>Sat, 01 Oct 2011 11:46:52 +0000</pubDate>
		<guid isPermaLink="false">http://www.v-nessa.net/2007/07/04/simple-mysql-search-query/#comment-11067</guid>
		<description>I would also recommend creating a blacklist of banned characters - % is a big one as it is the SQL wildcard. Enter that as your last name and you will receive all the database results. ;)</description>
		<content:encoded><![CDATA[<p>I would also recommend creating a blacklist of banned characters &#8211; % is a big one as it is the SQL wildcard. Enter that as your last name and you will receive all the database results. ;)</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: sonal</title>
		<link>http://www.v-nessa.net/2007/07/04/simple-mysql-search-query/comment-page-1#comment-9607</link>
		<dc:creator>sonal</dc:creator>
		<pubDate>Wed, 07 Jan 2009 04:29:45 +0000</pubDate>
		<guid isPermaLink="false">http://www.v-nessa.net/2007/07/04/simple-mysql-search-query/#comment-9607</guid>
		<description>hiiiiii</description>
		<content:encoded><![CDATA[<p>hiiiiii</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Lasse</title>
		<link>http://www.v-nessa.net/2007/07/04/simple-mysql-search-query/comment-page-1#comment-9168</link>
		<dc:creator>Lasse</dc:creator>
		<pubDate>Tue, 26 Feb 2008 19:48:18 +0000</pubDate>
		<guid isPermaLink="false">http://www.v-nessa.net/2007/07/04/simple-mysql-search-query/#comment-9168</guid>
		<description>hmm... I am having some problems with this. When i search using the code above I only recieve one result. And that&#039;s if I have more than one persons with same lastname. Example: I know I have 2 persons with the lastname: &quot;Planitzer&quot;. But when I search on the name only one is showing. Another problem is that this one person is the only one I can find. I have another person named &quot;Jensen&quot;. But the search function can&#039;t find him and is showing no results.  

Maybe it&#039;s just me and my coding.. I&#039;m still a new one in this area :)</description>
		<content:encoded><![CDATA[<p>hmm&#8230; I am having some problems with this. When i search using the code above I only recieve one result. And that&#8217;s if I have more than one persons with same lastname. Example: I know I have 2 persons with the lastname: &#8220;Planitzer&#8221;. But when I search on the name only one is showing. Another problem is that this one person is the only one I can find. I have another person named &#8220;Jensen&#8221;. But the search function can&#8217;t find him and is showing no results.  </p>
<p>Maybe it&#8217;s just me and my coding.. I&#8217;m still a new one in this area :)</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: ninuhadida</title>
		<link>http://www.v-nessa.net/2007/07/04/simple-mysql-search-query/comment-page-1#comment-2054</link>
		<dc:creator>ninuhadida</dc:creator>
		<pubDate>Sun, 22 Jul 2007 10:17:31 +0000</pubDate>
		<guid isPermaLink="false">http://www.v-nessa.net/2007/07/04/simple-mysql-search-query/#comment-2054</guid>
		<description>you could even do this to protect against sql injection:

$lastName = mysql_real_escape_string($_POST[’lastName’]);

taken from php.net:

mysql_real_escape_string() calls MySQL&#039;s library function mysql_real_escape_string, which prepends backslashes to the following characters: \x00, \n, \r, \, &#039;, &quot; and \x1a.</description>
		<content:encoded><![CDATA[<p>you could even do this to protect against sql injection:</p>
<p>$lastName = mysql_real_escape_string($_POST[’lastName’]);</p>
<p>taken from php.net:</p>
<p>mysql_real_escape_string() calls MySQL&#8217;s library function mysql_real_escape_string, which prepends backslashes to the following characters: \x00, \n, \r, \, &#8216;, &#8221; and \x1a.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: [ knrlpanick ]</title>
		<link>http://www.v-nessa.net/2007/07/04/simple-mysql-search-query/comment-page-1#comment-1773</link>
		<dc:creator>[ knrlpanick ]</dc:creator>
		<pubDate>Thu, 12 Jul 2007 06:39:25 +0000</pubDate>
		<guid isPermaLink="false">http://www.v-nessa.net/2007/07/04/simple-mysql-search-query/#comment-1773</guid>
		<description>glad I could be of help.. :) I aim to please... anyhow, the real problem is that people will copy and paste said code into their application and leave themselves open to attack, I am sure you are aware of the security issues, but the people who are googling for someone to solve their code problems may not be... :) anyhow, I am sure I will criticize more of your code at some point in time *G*

You can always go criticize mine too if you want -- although I haven&#039;t updated my blog since January (looks like I am the lazy one....)</description>
		<content:encoded><![CDATA[<p>glad I could be of help.. :) I aim to please&#8230; anyhow, the real problem is that people will copy and paste said code into their application and leave themselves open to attack, I am sure you are aware of the security issues, but the people who are googling for someone to solve their code problems may not be&#8230; :) anyhow, I am sure I will criticize more of your code at some point in time *G*</p>
<p>You can always go criticize mine too if you want &#8212; although I haven&#8217;t updated my blog since January (looks like I am the lazy one&#8230;.)</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Tech Tools</title>
		<link>http://www.v-nessa.net/2007/07/04/simple-mysql-search-query/comment-page-1#comment-1611</link>
		<dc:creator>Tech Tools</dc:creator>
		<pubDate>Sat, 07 Jul 2007 20:58:05 +0000</pubDate>
		<guid isPermaLink="false">http://www.v-nessa.net/2007/07/04/simple-mysql-search-query/#comment-1611</guid>
		<description>Handy Dandy</description>
		<content:encoded><![CDATA[<p>Handy Dandy</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Nessa</title>
		<link>http://www.v-nessa.net/2007/07/04/simple-mysql-search-query/comment-page-1#comment-1585</link>
		<dc:creator>Nessa</dc:creator>
		<pubDate>Sat, 07 Jul 2007 05:48:58 +0000</pubDate>
		<guid isPermaLink="false">http://www.v-nessa.net/2007/07/04/simple-mysql-search-query/#comment-1585</guid>
		<description>&lt;p&gt;DOH!  Actually, I&#039;d prefer to just turn on register globals and not use $var = $_POST at all  =D&lt;/p&gt;
&lt;p&gt;Thanks for pointing that out...you just made me realize how lazy of a coder I am, and I&#039;ve now lost all ambition and hope in life.&lt;/p&gt;
&lt;p&gt;hehehe&lt;/p&gt;
</description>
		<content:encoded><![CDATA[<p>DOH!  Actually, I&#8217;d prefer to just turn on register globals and not use $var = $_POST at all  =D</p>
<p>Thanks for pointing that out&#8230;you just made me realize how lazy of a coder I am, and I&#8217;ve now lost all ambition and hope in life.</p>
<p>hehehe</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: [ knrlpanick ]</title>
		<link>http://www.v-nessa.net/2007/07/04/simple-mysql-search-query/comment-page-1#comment-1532</link>
		<dc:creator>[ knrlpanick ]</dc:creator>
		<pubDate>Thu, 05 Jul 2007 19:46:10 +0000</pubDate>
		<guid isPermaLink="false">http://www.v-nessa.net/2007/07/04/simple-mysql-search-query/#comment-1532</guid>
		<description>this is also the #1 cause of SQL Injection vulerabilities in php web applications, so please, by all means, sprinkle this code throughout every last bit of your website.. :) -- or you could fix it by simply changing the line:

$lastName = $_POST[’lastName’];

to 

$lastName = ereg_replace(&quot;[^a-z0-9A-Z]&quot;, &quot;&quot;, $_POST[’lastName’] ); 

granted this is not the best practice and not the best action, however, it will save you alot of grief if you are doing this on some type of publicly accessible page.</description>
		<content:encoded><![CDATA[<p>this is also the #1 cause of SQL Injection vulerabilities in php web applications, so please, by all means, sprinkle this code throughout every last bit of your website.. :) &#8212; or you could fix it by simply changing the line:</p>
<p>$lastName = $_POST[’lastName’];</p>
<p>to </p>
<p>$lastName = ereg_replace(&#8220;[^a-z0-9A-Z]&#8220;, &#8220;&#8221;, $_POST[’lastName’] ); </p>
<p>granted this is not the best practice and not the best action, however, it will save you alot of grief if you are doing this on some type of publicly accessible page.</p>
]]></content:encoded>
	</item>
</channel>
</rss>

