Hi, I'm making litle CMS with PHP+Mysql. Can you tellme measures for prevention for SQL Injections ?
ultras1
0
Newbie Poster
Recommended Answers
Jump to Postusing php base64_encode and php base64_decode can help as well.
never run a query on data you unsure about.
also, its a good idea to restrict the permissions of the mysql user your scripts are using, so in case someone does get in, they can't create, alter or …
Jump to PostWhen creating links use:
$id=33; $page=1; $link = "index.php?id=".base64_encode($id)."&page=".base64_encode($page);
Then when getting those variables:
$id = base64_decode($_GET['id']); $page = base64_decode($_GET['page']);
hope that helps.
All 6 Replies
smartness
-3
Junior Poster
kylegetson
16
Junior Poster in Training
darkagn
commented:
Great suggestions
+3
ultras1
0
Newbie Poster
kylegetson
16
Junior Poster in Training
mwasif
10
Posting Whiz
koldex
0
Newbie Poster
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.