How to go to a title id page

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
CoolAsCarlito
Forum Contributor
Posts: 192
Joined: Sat May 31, 2008 3:27 pm
Contact:

How to go to a title id page

Post by CoolAsCarlito »

I have a title histories page that stores all my titles and when you click on a pic of one of the titles I want it to go to titlehistory.php?id=1. I have it linked correctly so that it shows the correct link but I'm still lost how it will actually go to that titles page info and what not.
desmi
Forum Commoner
Posts: 64
Joined: Sun Jun 15, 2008 4:55 am

Re: How to go to a title id page

Post by desmi »

Please post your code.. but you need to use method GET to load the correct id:

Code: Select all

<?php
   $idyouwant = $_GET['id'];
   //you put this on that titlehistory page, and after that you play with your variable, lets say eg. :
 
   echo $idyouwant;
 
   // or
 
   mysql_query("SELECT * FROM table WHERE id = '$id'") or die(mysql_error());
 
Post Reply