开发者

Parse error: syntax error, unexpected ';' [closed]

This question is unlikely to help any future visitors; it is only relevant to a small geographic area, a specific moment in time, or an extraordinarily narrow situation that is not generally applicable to the worldwide audience of the internet. For help making this question more broadly applicable, visit the help center. Closed 9 years ago.

Hallo

I have this script:

<?
  require("lib2/config.inc.php");
  require("lib2/tpl.class.php");
  require("lib2/db.class.php");
  require("lib2/um.class.php");


  $tpl          = new template("templates", "tpl");
  $db         = new db($db['location'], $db['username'], $db['passwort'], $db['database']);
  $um         = new usermanagment();


  /** User login **/

  $checklogin       = $um->check_login();
  $userdata       = $um->getuserdata();

  if(!$checklogin && !$guest) {
    header("LOCATION: ./index2.php");
  }

  eval("\$header .= \" ".$tpl->get("header")."\";");
  eval("\$footer .= \" ".$tpl->get("footer")."\";");

$time     = time();
$db->Query("UPDATE userdaten SET lastaction = '$time' WHERE userid = '".$userdata['userid']."'");
?>

And get this error: Parse error: syntax error, unexpected ';' in /home/httpd开发者_如何学JAVA/html/login/global.php(22) : eval()'d code on line 96

Any ideas?


At first look you ... the error is probably in the code passed to the function eval().

Note: I do not use the function eval(). It can cause hidden mistakes, which are difficult to find.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜