好的,所以这似乎很常见,但我读过的东西都没有帮助我,所以有没有人知道为什么我的变量似乎没有设置..
编辑:抱歉忘记了错误的位置,它在第 169 行,即:
if($world['$queryi'] != 0)
<?php
if(isset($_GET['upgrade']))
{
if($_GET['upgrade'] > 0 && $_GET['upgrade'] < 15){
$_GET['upgrade'];
$id = $_GET['upgrade'];
$queryi = "column_$id"; // This shows as undefined.
$querye = "column_name_$id"; // This shows as undefined
//When printing them out alone, they are defined, with the value i need them to be.
if($id>=1 && $id <=14)
{
//$world[] <- array from outside of the $_GET area (ive tried having it inside, same error)
if($world['$queryi'] != 0)
{
}
else
{
echo "query turned out zero";
}
}
else
{
echo "something went wrong.";
}
}
}
?>
//EDIT this is the arrayQUery which seems to be causing the problem..
$query = "SELECT * from this WHERE userid='".$user['id']."'";
$result = mysql_query($query);
$world=mysql_fetch_array($result);
有没有人有线索,怎么了?