Hi. i was wondering if somebody could help me. Im looking for a php function to check a get and post methods for any type of hack or injection i.e. xss php java html mysql injection. the function needs to check the get or post methods prior to using it and checking against the database. would be greatfull if somebody could give me an example on how to achieve this.


I am not sure whether I understood your question correctly.
Do want to make sure the GET and POST variables sent from client side to the server are not altered inbetween? If so how about generating a hash value?
Sorry if I misunderstood your question

you can use the strip_tags function and sanatize your data