Hello
I am inserting data into my database, and my PHP is currently setup with magic quotes set to ON, so that it automatically escapes slashes.
I am interested to know the proper use of addslashes. I am now thinking of passing the data uploaded to my database through the addslashes and stripslashes functions to make sure that my code will work on another installation of PHP with magic quotes set to OFF.
Is it worth my time adding in the addslashes function to aid in portability to other systems, and also if i did use it would it add slashes twice when magic quotes is set to ON as well. Should I check if Magic quotes is set to ON and only use the addsalshes function if it is OFF
I hope that this makes somse sense
Thanks
Ian