[Help] Display Each Form Entry As A New Item

Discussion in 'PHP' started by BirdOfPrey, Jun 1, 2010.

  1. #1
    Well, I am trying to create a mailing list for a new site I am launching.

    I want to display an input field for people to put their email address in, then it shows up on a page with a list of all emails who have signed up.

    But the problem, I can only get the most recent entry to show up. Here is my HTML code:

    	
    <form method="post" action="list.php">
    	
    	<input type="text" name="email" />
    		
    	<input type="submit" value="submit" name="submit" />
    		
    </form>
    
    Code (markup):
    If someone could kindly explain how to use that code, but display each new entry in a list on list.php, I would greatly appreciate it.
     
    BirdOfPrey, Jun 1, 2010 IP
  2. cshwebdev

    cshwebdev Active Member

    Messages:
    226
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    80
    #2
    How are you storing the information? Through a database (i.e. MySQL, SQLlite) or in a text file.

    Once someone submits the form it'll need to be stored somewhere so you can access it later. So, once someone has submitted their email, it'll need to go to the location, add it, than pull the information out again, which will show ALL of the emails.
     
    cshwebdev, Jun 1, 2010 IP
  3. BirdOfPrey

    BirdOfPrey Peon

    Messages:
    32
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    0
    #3
    Oh, wow, haha, I forgot about storing the information. I'm stupid. Thank you though, you jogged my memory on how to do this.
     
    BirdOfPrey, Jun 1, 2010 IP