uzairrahim Posted October 29, 2007 Share Posted October 29, 2007 Hi, I am new to PHP and MySQL, though i have a good command on ActionScript 2.0 I am working on an application that is based on Flash, PHP and MySQL. From the Flash file i m sending a string variable to PHP to store in the database, the string is a path to a directory on a local network "\\aus-fs-1\development\content..." but when i look into the database the string is stored as "\aus-fs-1developmentcontent...", missing all the slashes, except for the first one. Could anyone tell me how to deal with this problem. Thanks Quote Link to comment https://forums.phpfreaks.com/topic/75258-having-trouble-with/ Share on other sites More sharing options...
redbullmarky Posted October 29, 2007 Share Posted October 29, 2007 with the variable you're using, are you running the data through stripslashes at all before putting it in the DB? if there are no "escaping" slashes in the string (ie, the result of running the data through addslashes/mysql_real_escape_string), then it'll take out others with undesirable results. Quote Link to comment https://forums.phpfreaks.com/topic/75258-having-trouble-with/#findComment-380655 Share on other sites More sharing options...
uzairrahim Posted October 29, 2007 Author Share Posted October 29, 2007 never heard of stripslashes before i am a noob i am storing the value from flash into a variable in PHP and then directly entering the value (from the php variable) into the DB, how can i fix the problem? Quote Link to comment https://forums.phpfreaks.com/topic/75258-having-trouble-with/#findComment-380660 Share on other sites More sharing options...
uzairrahim Posted October 29, 2007 Author Share Posted October 29, 2007 ok i used addslashes() and it works for me Thanks, Quote Link to comment https://forums.phpfreaks.com/topic/75258-having-trouble-with/#findComment-380663 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.