JS和PHP脚本无法在Chrome或IE8中加载

时间:2012-09-28 21:38:29

标签: php javascript frontpage-extensions

JS和PHP脚本无法在Chrome或IE下正确加载。我正在使用FrontPage 2003(SP-3)开发一个支持视频游戏开发的家庭企业网站。

<?PHP
if(strstr($_SERVER["HTTP_USER_AGENT"],"MSIE")==false) {
header('Content-type: text/javascript');
header("Content-Disposition: inline; filename=\"register.js\"");

 } else {
      header("Content-type: text/force-download");
      header("Content-Disposition: attachment; filename=\"register.js\"");

 } else {
 <Location register.js>
      ForceType ('application/x-httpd-php')
</Location>
}

require_once("./include/membersite_config.js");


if(isset($_POST['submitted']))
{
   if($fgmembersite->RegisterUser())
   {
        $fgmembersite->RedirectToURL("thank-you.html");
   }
}

?>

1 个答案:

答案 0 :(得分:2)

} else {
 <Location register.js>
      ForceType ('application/x-httpd-php')
</Location>
}

这不是有效的PHP ...(你会很好地听AlienWebguy的建议)