ElitesHost Forums
Anti - MYSQL Injection for samp - Printable Version

+- ElitesHost Forums (https://forum.eliteshost.com)
+-- Forum: Services (https://forum.eliteshost.com/forumdisplay.php?fid=4)
+--- Forum: Problems & Suggestions (https://forum.eliteshost.com/forumdisplay.php?fid=20)
+--- Thread: Anti - MYSQL Injection for samp (/showthread.php?tid=246)



Anti - MYSQL Injection for samp - denisa - 08-25-2017

Step 1:
We create a static, go up in the gamemode after the last #include
 
And add this static:
Static const antisqlinjection [] [] =
{
    "" "
    "#"
    "` "
    "% S",
    "% D",
    "% F"
};
Step 2:
 
We go to OnDialogResponse and add this function:
For (new i; i <sizeof (antisqlinjection); i ++)
{
    If (strfind (inputtext, antisqlinjection [i], true)! = -1)
    {
        SCM (playerid, -1, "No such characters allowed");
        Return 1;
    }
}



RE: Anti - MYSQL Injection for samp - joker123 - 08-25-2017

Thx for sharing @denisa
Are you new here?
You can introduct yourself here: https://forum.elites-host.com/forumdisplay.php?fid=28


RE: Anti - MYSQL Injection for samp - PotatoM - 08-27-2017

And what this supposed to do?