Jump to content

[SOLVED] variable wont show up


AJxr

Recommended Posts

hi all, im a super newb. ive been reading for a couple days now and i just cant find my problem. i have a movie website with a simple database using mysql and php etc. ive tried searching here but my terminology just isnt up to par i guess.

 

anywho i have hosting with nexcess.net and it uses php 5.2.6... etc....

 

my problem is that i cannot get the variable (ie. page.php?id=2) to show up on the website page.

 

even when i use this code to test.

 

<?php

print "the id is $id<br>\n";

 

?>

 

im trying to select data from tablex WHERE id=$id.

 

if i type select * from tablex WHERE id=2 instead of the variable $id (when the browser says page.php?id=2) the info comes up.

 

sorry for the confusion if any but my little head hurts from trying to figure this plain old stuff out.

Link to comment
https://forums.phpfreaks.com/topic/168353-solved-variable-wont-show-up/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.