jayteepics Posted August 8, 2011 Share Posted August 8, 2011 echo "<input type='text' name='arr[$title]' value='$qty' size='3'>"; I chose to use book titles as my MySQL primary key as not all books have ISBN. Thing is I have everything else working (using Titles) including changing a book's quantity on a form thanks to folks on this forum. However if a book has an apostrophy in it's title, I get multiple arrays created. Is it possible to rectify this please? Jamie Link to comment https://forums.phpfreaks.com/topic/244223-can-this-code-be-tweaked-to-work-with-titles-containing-apostrophies-please/ Share on other sites More sharing options...
PFMaBiSmAd Posted August 8, 2011 Share Posted August 8, 2011 This should solve the problem - http://www.phpfreaks.com/forums/index.php?topic=340817.msg1607027#msg1607027 If not, you would need to define: "I get multiple arrays created" Link to comment https://forums.phpfreaks.com/topic/244223-can-this-code-be-tweaked-to-work-with-titles-containing-apostrophies-please/#findComment-1254348 Share on other sites More sharing options...
jayteepics Posted August 8, 2011 Author Share Posted August 8, 2011 This should solve the problem - http://www.phpfreaks.com/forums/index.php?topic=340817.msg1607027#msg1607027 If not, you would need to define: "I get multiple arrays created" Indeed it did!! Thank you again!! Phew! So much to learn - but that can't be a bad thing - however if you were not so helpful over this issue I would have no hair left. Much appreciated Jamie Link to comment https://forums.phpfreaks.com/topic/244223-can-this-code-be-tweaked-to-work-with-titles-containing-apostrophies-please/#findComment-1254418 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.