php-5.3.3 连接 mssql 失败?解决思路

WBOY
Release: 2016-06-13 13:31:26
Original
597 people have browsed it

php-5.3.3 连接 mssql 失败?
我下载php-5.3.3-Win32-VC6-x86(是在http://windows.php.net/download/ 下载的)
我在php.ini中把连接mssql的配置都打开.
但下载包中没有包含php_mssql.dll,只有php_mysql.dll
我在网上重新下载php_mssql.dll文件加载 "\ext"目录下
但重启Apache 就提出警告说找不到该模块。

$hostname="10.4.2.5"; //正确
$dbuser="sa"; //正确
$dbpasswd="123456"; //正确
$dbname="HR"; //正确
$conn = mssql_connect($hostname,$dbuser,$dbpasswd) or die("数据库连接错误!"); 
mssql_select_db($dbname,$conn); 
$sql = " select * from Pip_Staff_S where cStaffID ='z797' "; 
$rowset=mssql_Query($sql,$conn); 
$rowcnt=mssql_num_row($rowset);
echo " Rows ";
//echo $rowset;
echo "Word Hello";
echo " END ";
?>
运行的时候也在错误"Fatal error: Call to undefined function mssql_connect() "

是不是php-5.3.3没有直接包含php_mssql.dll..

怎么才能实现连接mssql?


------解决方案--------------------

------解决方案--------------------
正确听听吧

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!