IIS+PHP配置问题,求教!
我的系统是win2003,装好IIS后,能正常浏览目录下的HTML页。然后我用PHP 5.2.2insta进行安装,选择的安装模式是CGI,装好之后,凡是PHP页都无法浏览,提示无法找到该页!请问这是怎么一回事?我换了ISAP模式也还是一样的结果!
另外还有一台服务器(不是我配置的),运行一个PHP网站正常,但是登陆后台却没有反应,这又是怎么一回事啊?登陆页的代码如下:
<?php require_once( 'hr.php '); ?>
<?php
// *** Start the session
session_start();
// *** Validate request to log in to this site.
$FF_LoginAction = $HTTP_SERVER_VARS[ 'PHP_SELF '];
if (isset($HTTP_SERVER_VARS[ 'QUERY_STRING ']) && $HTTP_SERVER_VARS[ 'QUERY_STRING ']!= " ") $FF_LoginAction .= "? ".$HTTP_SERVER_VARS[ 'QUERY_STRING '];
if (isset($HTTP_POST_VARS[ 'Username '])) {
$FF_valUsername=$HTTP_POST_VARS[ 'Username '];
$FF_valPassword=$HTTP_POST_VARS[ 'UserPwd '];
$FF_fldUserAuthorization= "hr_type ";
$FF_redirectLoginSuccess= "../index.php ";
$FF_redirectLoginFailed= "../lost.php ";
$FF_rsUser_Source= "SELECT hr_id, hr_pw ";
if ($FF_fldUserAuthorization != " ") $FF_rsUser_Source .= ", " . $FF_fldUserAuthorization;
$FF_rsUser_Source .= " FROM hr WHERE hr_id= ' " . $FF_valUsername . " ' AND hr_pw= ' " . $FF_valPassword . " ' ";
mysql_select_db($database_hr, $hr);
$FF_rsUser=mysql_query($FF_rsUser_Source, $hr) or die(mysql_error());
$row_FF_rsUser = mysql_fetch_assoc($FF_rsUser);
if(mysql_num_rows($FF_rsUser) > 0) {
// username and password match - this is a valid user
$MM_Username=$FF_valUsername;
session_register( "MM_Username ");
if ($FF_fldUserAuthorization != " ") {
$MM_UserAuthorization=$row_FF_rsUser[$FF_fldUserAuthorization];
} else {
$MM_UserAuthorization= " ";
}
session_register( "MM_UserAuthorization ");
if (isset($accessdenied) && false) {
$FF_redirectLoginSuccess = $accessdenied;
}
mysql_free_result($FF_rsUser);
session_register( "FF_login_failed ");
$FF_login_failed = false;
header ( "Location: $FF_redirectLoginSuccess ");
exit;
}
mysql_free_result($FF_rsUser);
session_register( "FF_login_failed ");
$FF_login_failed = true;
header ( "Location: $FF_redirectLoginFailed ");
exit;
}
?>
这个网站我在本地测试时没有发生任何问题!期待高手帮忙解决!
[解决办法]
到我博客看最详细的windows下php安装教程:
http://indian.blog.163.com/blog/static/10881582007018581243