Preventing SQL Injection


Posted on 16th Feb 2014 07:03 pm by admin

I have a question about SQL Injection, In some of our code we use this: view plaincopy to clipboardprint?Replace(inString, "'", "''") Replace(inString, "'", "''") does this prevent all forms of SQL Injection? Also what exactly does parameterized statements do?view plaincopy to clipboardprint?myCommand.Parameters.AddWithValue("@username", user); myCommand.Parameters.AddWithValue("@password", pass);
No comments posted yet

Your Answer:

Login to answer
202 Like 50 Dislike
Previous forums Next forums
Other forums

Multi Level Array Problem
hi all,

For example I have array like below:

$temp = array(array('north america', 'us'

Why doesn't this work? (SSH2)
This is my script:

Code: <?php
$connection = ssh2_connect('213.251.167.109', 22);

values not being entered into table
hi. I;ve created a form, so that when a user enters data into it, it gets added to a table in a data

Cursor statement failed with errors
Following statement failed with the errors.

cursor proj_cursor1 is (select projectID from

Showing selected item at top of list
Hi,

I've got a list of names which i am fetching from database like this:
$qry = db_query

Is it possible to put an entire 500-page book in a database with PHP?
I am working on an intranet and I was wondering if its possible to code php with mysql to enter a fu

LOOPing Problem
Hello All!

The following code loops through the data and displays the data accordingly. My p

Help Optimizing code
Good Morning,

I wrote a small import function for a website of mine and I know there has to b

How do I use ValidatorCallout extender in Login control?
Hi,I'd like to customize the look and feel of the login control a little bit. One thing I'd love to

Auto-populating dropdowns and multiple forms.
Here's what I have so far:

First drop down = select a state (works)
This populates the sec

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash