Fastest Web Hosting

what do i need to escape when sending a query?

0 votes
asked Nov 11, 2016 in Mysql by rajatinsa (3,350 points)

User can create sql query on my website. many time hacker trying to fetch out unnecessary result. i want to secure my website

1 Answer

0 votes
answered Nov 11, 2016 by Manoj Insan (1,600 points)

Use mysql_real_escape_string to secure posted query by user in below way

$param = mysql_real_escape_string($post_variable['param']);

select * from table where table_row = $param

Job Board

TechnicalSharp is a technical community of developers where they are sharing their knowledge and solutions and against it they are getting the score point which help them to make profile strong which is under eyes on MNC's
...