coops Posted October 5, 2007 Share Posted October 5, 2007 Hi, I’m trying to place the data from a textbox within a form into a Variable, but I seem to be having problems. The problem is when it comes to a ‘ e.g. “it’s” or “don’t” the value of the string changes from “don’t” to a “don\’t”. Does anyone know anything that will stop this happening? Link to comment https://forums.phpfreaks.com/topic/71949-retrieving-data-from-textboxs/ Share on other sites More sharing options...
RichardRotterdam Posted October 5, 2007 Share Posted October 5, 2007 i dont think you can retrieve text with plain html show some code so the problem can be determined I think you are using javascript so it should be moved to javascript help Link to comment https://forums.phpfreaks.com/topic/71949-retrieving-data-from-textboxs/#findComment-362381 Share on other sites More sharing options...
coops Posted October 5, 2007 Author Share Posted October 5, 2007 Ok the data is in a textbox called "txtCustomerName" <input name="txtCustomerName" type="text" id="1"> The below code is used to retrieve the data and the echo will be it\'s echo $moduleCustName = valuator($_POST['txtCustomerName']); Link to comment https://forums.phpfreaks.com/topic/71949-retrieving-data-from-textboxs/#findComment-362384 Share on other sites More sharing options...
coops Posted October 5, 2007 Author Share Posted October 5, 2007 Found out that its something to do with the $_POST or the form setup. As if I place the data straight into the fucntion as a string , there is no problems... Does anyone know of a way around this problem? Link to comment https://forums.phpfreaks.com/topic/71949-retrieving-data-from-textboxs/#findComment-362404 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.