Jump to content

T_variable error


Scummy12

Recommended Posts

<?php
$iStatList= file_get_contents("http://75.126.76.220/mob_hi5/get_hit_list?user_id=492711089&level=1&session_id=b00b6b4d2d7b124a41c3c5650af902fe5f718a61&auth_key=b00d1f9387158859780c072555ed822124728e57&original_url=http://75.126.76.220/mob_hi5/get_hit_list&nocache=1274268208017&");
	$amount = 	split("<amount>", $iStatList);
	$amount = 	split("<", $level[1]);
	$level=   split("<level>", $iStatList);
	$level=	split("</level>", $level[1]);
	$user_id= split("<user_id>", $iStatList);
	$user_id= split("</user_id>", $user_id[1]);
echo $user_id[0];
echo $level[0];
if ($level[0]>20)
	{	header("Location: http://75.126.76.220/mob_hi5/attack_hitlist?user_id=492711089&target_id="$user_id[0]"&session_id=b00b6b4d2d7b124a41c3c5650af902fe5f718a61&auth_key=b00d1f9387158859780c072555ed822124728e57&original_url=http://75.126.76.220/mob_hi5/attack_hitlist&nocache=1274268208017&");
}

elseif 
{echo "no targets"}

?>

Parse error: syntax error, unexpected T_VARIABLE in C:\xampp\htdocs\statlist.php  on line 12

Anybody know why?

Link to comment
https://forums.phpfreaks.com/topic/202319-t_variable-error/
Share on other sites

You're not concatenating the string correctly.

 

header("Location: http://75.126.76.220/mob_hi5/attack_hitlist?user_id=492711089&target_id=" . $user_id[0] . "&session_id=b00b6b4d2d7b124a41c3c5650af902fe5f718a61&auth_key=b00d1f9387158859780c072555ed822124728e57&original_url=http://75.126.76.220/mob_hi5/attack_hitlist&nocache=1274268208017&");

Link to comment
https://forums.phpfreaks.com/topic/202319-t_variable-error/#findComment-1060873
Share on other sites

After you fix the errors that AlexWD pointed out in the statlist.php code, you will need to do something about the error in cider.php.

 

 

That is the entire script

 

That's not where the error you just posted is occurring at. Please read your error messages and the replies people post.

Link to comment
https://forums.phpfreaks.com/topic/202319-t_variable-error/#findComment-1060884
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.