Hi there. Sharon here🙂 How do I pass a variable in a url. Here is my url... <a href= static.php> Edit </a> I was looking to pass a variable to my next page so I can use it in a query.
OK. I think i figured it out.
<a href= static.php?id=$id> Edit </a>
Does that look good to you guys?? Now how is that variable available on the next page? Is the variable $id now available or do I have to use another method. Sharon
<a href="static.php?id=<?php echo $id?>">
And it's availabel in static.php as $_GET['id'].
Full details http://www.php.net/manual/en/language.variables.external.php