Photo Gallery help for Newbie

Discussion in 'PHP' started by camdes, Apr 28, 2008.

  1. #1
    Excuse the complete newbie question.

    I am building a photo gallery using PHP and MySQL. I have the thumbnail page and the large photo page and when I show one of the photographs I wish to put a "next" and "previous" link on the page. Do I need to put these in a form so that I can send the id of the photograph to the next page to query the database for the next or previous photo.
     
    camdes, Apr 28, 2008 IP
  2. Louis11

    Louis11 Active Member

    Messages:
    783
    Likes Received:
    26
    Best Answers:
    0
    Trophy Points:
    70
    #2
    You can send this info via a link.

    For example: photo_gallery.php?photoID=4

    Make sure you strip the tags on this get request, however, as it could lead to XSS in your web application.

    Cheers,
    Louis
     
    Louis11, Apr 28, 2008 IP
  3. PowerExtreme

    PowerExtreme Banned

    Messages:
    2,118
    Likes Received:
    75
    Best Answers:
    0
    Trophy Points:
    0
    #3
    use the GET function
     
    PowerExtreme, Apr 28, 2008 IP