Results 1 to 2 of 2

Thread: How to store check box values in php sessions?

  1. #1

    Thread Starter
    Frenzied Member
    Join Date
    Apr 2005
    Posts
    1,907

    Lightbulb How to store check box values in php sessions?

    Hi all i got a few checkboxes and i let the user to select a few of them and then click a submit button. I want store the value of select checkbox in sessions and later one use them. could any one show me how i can do that.Thanks

    Code:
    <form action="./write.php" method=post >
    
    <input type="checkbox" name="id" value="1"
    <input type="checkbox" name="id" value="2"
    <input type="checkbox" name="id" value="3"
    
    <input type="submit" value="Add this/these Songs to my PlayList" name="B1">

  2. #2
    Frenzied Member sciguyryan's Avatar
    Join Date
    Sep 2003
    Location
    Wales
    Posts
    1,763

    Re: How to store check box values in php sessions?

    OK.

    Firstly the correct version fo the code you posted above is

    Code:
    <form action="./write.php" method="post">
      <input type="checkbox" name="id" value="1" />
      <input type="checkbox" name="id" value="2" />
      <input type="checkbox" name="id" value="3" />
    
      <input type="submit" value="Add this/these Songs to my PlayList" name="B1" />
    </form>
    Now I suggest you read this, it should provide you with the inslight you need

    Cheers,

    Ryan Jones
    My Blog.

    Ryan Jones.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width