2 Replies - 13311 Views - Last Post: 16 July 2010 - 06:00 AM Rate Topic: -----

#1 vasanth1  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 11
  • Joined: 12-July 09

Inserting multiple checkbox values into one column of the database

Post icon  Posted 21 July 2009 - 10:57 PM

Hi,



How to insert multiple checkbox values(from php) into one column of the database(mysql)?.


Suppose if a checkbox contain 4 valuesif i choose 3 fvalues,then how to insert that 3 values into the single table


Anyone can you reply me

Thanx
Is This A Good Question/Topic? 0
  • +

Replies To: Inserting multiple checkbox values into one column of the database

#2 JBrace1990  Icon User is offline

  • D.I.C Addict
  • member icon

Reputation: 112
  • View blog
  • Posts: 760
  • Joined: 09-March 08

Re: Inserting multiple checkbox values into one column of the database

Posted 21 July 2009 - 11:21 PM

you could use serialize() and unserialize().
Was This Post Helpful? 0
  • +
  • -

#3 Guest_Guest*


Reputation:

Re: Inserting multiple checkbox values into one column of the database

Posted 16 July 2010 - 06:00 AM

The thiis the same as when you want to insert like name but when you read the values from the form delimit them with a comma or any delimiter and you can split that up for display and it can be readily displayed with commas

Also mysql has a type called enum or set which takes comma delimited values

Hope that this will help,Thanx
Was This Post Helpful? 0

Page 1 of 1