Renegade Public Forums
C&C: Renegade --> Dying since 2003™, resurrected in 2024!
Home » Technical Support » Other » PHP issue
Re: PHP issue [message #439808 is a reply to message #438943] Sat, 20 November 2010 16:04 Go to previous messageGo to previous message
Omar007 is currently offline  Omar007
Messages: 1711
Registered: December 2007
Location: Amsterdam
Karma:
General (1 Star)
Does the first query return something? Also according to your code, if name = renegade then it will search in your next statement for the table renegadex. I'm assuming that table is present?

This is how I would write that piece of code. I don't think it matters but w/e

$pid = $_GET['id'];
$index = mysql_query("SELECT * FROM index where id = '".$pid."'") or die(mysql_error());
$row = mysql_fetch_array($index);
$thisvar = $row['name'] . "x";
echo $thisvar; //Check here
$query = mysql_query("SELECT * FROM ".$thisvar." where uid = '".$_SESSION['id']."'") or die(mysql_error());
$row1 = mysql_fetch_array($query); 
$uid = $row1['id'];
echo $uid;


http://tiberiumredux.omarpakker.nl/Old Unused Parts/Plaatjes/PromoteBanner_Hades_small.jpg
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: GameSpy
Next Topic: Generals... AGAIN
Goto Forum:
  


Current Time: Fri Nov 22 19:40:25 MST 2024

Total time taken to generate the page: 0.01197 seconds