SitePoint Sponsor

User Tag List

Results 1 to 5 of 5
  1. #1
    SitePoint Member
    Join Date
    Mar 2005
    Posts
    24
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Question Cookie Building - Using input form

    Hi guys,

    Having spent a good while reading the various articles and threads on this site, and numerous others, it seems that i'll have to admit defeat and see if i can get any help.

    Hopefully the thread title gives you a clue to what i'm trying to do but here goes in a bit more detail.

    The problem occurs when i want to have a form (off the main form)which allows visitors to add an infinite number of comments about a topic. So the visitor goes on, fills in the comment (which stores to a cookie)and then if desired clicks add another comment. The form then clears out and the user can add another comment which will save in the same cookie but not overwrite the first comment. The user should be able to fill in an infinite number of comments which will build up in the cookie and then when finished click another submit button which will take them back to the main form with a nice thanks for entering your comments response.

    Firstly is this possible, i can't find anything about it. If so, could you give me any pointers.

    Thanks.
    Andy

  2. #2
    SitePoint Member
    Join Date
    Mar 2005
    Posts
    24
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Whoops think i'd of been better sticking this in the normal php forum.

  3. #3
    simple tester McGruff's Avatar
    Join Date
    Sep 2003
    Location
    Glasgow
    Posts
    1,690
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Remember there is a 4kb limit on cookie size. http://wp.netscape.com/newsref/std/cookie_spec.html

  4. #4
    SitePoint Wizard DougBTX's Avatar
    Join Date
    Nov 2001
    Location
    Bath, UK
    Posts
    2,498
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by Dufresne
    Firstly is this possible, i can't find anything about it. If so, could you give me any pointers.
    Try using sessions instead of using cookies directly: http://www.php.net/manual/en/function.session-start.php

    Douglas
    Hello World

  5. #5
    SitePoint Wizard
    Join Date
    Oct 2001
    Posts
    2,686
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)


Bookmarks

Posting Permissions

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