Jump to content

[SOLVED] Form Array help


Andrew R

Recommended Posts

I have the following form array.....

 

<form id="form1" name="form1" method="post" action="post.php">
  <label>
  <input name="user_id[]" type="checkbox" id="user_id[]" value="1" />
  </label>
  Andrew<br />
  <label>
  <input name="user_id[]" type="checkbox" id="user_id[]" value="2" />
  </label>
  Jim<br />
  <label>
  <input name="user_id[]" type="checkbox" id="user_id[]" value="3" />
  </label> 
  James
</form>

 

How would I combine user_id[] into 1 variable which would contain the values separated by a comma so it could be passed into a sql statement.

 

Many thanks

Link to comment
https://forums.phpfreaks.com/topic/144776-solved-form-array-help/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.