feri_soft Posted September 1, 2006 Share Posted September 1, 2006 How to add to the datatbase items from a multiple select in one field seperated by comas.For example i have a select called extras and it has Tvfridgepoolan so on.how can i add the values a user have selected into the databse seperated by comma.likeextras: tv,poolThanks Quote Link to comment Share on other sites More sharing options...
scottybwoy Posted September 1, 2006 Share Posted September 1, 2006 Are you using a radio buttins as a means of selection or what? You could put the results in an array and use implode. Quote Link to comment Share on other sites More sharing options...
feri_soft Posted September 1, 2006 Author Share Posted September 1, 2006 I use a <select name="asdasd" multiple><option>........</select>how exatcly to do the job,can you give me a working example Quote Link to comment Share on other sites More sharing options...
scottybwoy Posted September 1, 2006 Share Posted September 1, 2006 If your looking how to select multiple items in one selection box, then I do not know how to do it, without having multiple submit or select boxes, very messy? Also are you getting your options from a database or are they static? Quote Link to comment Share on other sites More sharing options...
feri_soft Posted September 1, 2006 Author Share Posted September 1, 2006 They are static....its easy to select some options holding control and clicking on different options but in the database there is only the first option you clicked!? Quote Link to comment Share on other sites More sharing options...
tomfmason Posted September 1, 2006 Share Posted September 1, 2006 try printing the asdasd field. Like this.[code=php:0]print_r($asdasd);[/code]See if that returns an array with the multipule options.Good luck,Tom Quote Link to comment Share on other sites More sharing options...
feri_soft Posted September 2, 2006 Author Share Posted September 2, 2006 I founded the solution with implode and explode... Quote Link to comment 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.