目前共有10篇帖子。 字体大小:较小 - 100% (默认)▼  内容转换:大陆简体▼
 
点击 回复
1413 9
靠,PHP官方已经提醒大家不要再用mysql_connect了,提醒改用mysqli或PDO
一派掌门 二十级
1楼 发表于:2015-5-31 08:20
mysql_connect (PHP 4, PHP 5)
mysql_connect — Open a connection to a MySQL Server
Warning This extension is deprecated as of PHP 5.5.0, and will be removed in the future. Instead, the MySQLi or PDO_MySQL extension should be used. See also MySQL: choosing an API guide and related FAQ for more information. Alternatives to this function include:


mysqli_connect()
PDO::__construct()

http://php.net/manual/en/function.mysql-connect.php
一派掌门 二十级
2楼 发表于:2015-5-31 08:21
在PHP5.5.0中被抛弃,在将来的版本会彻底移除!
 
一派掌门 二十级
3楼 发表于:2015-5-31 09:00
This extension is deprecated as of PHP 5.5.0,
整个mysql扩展在PHP5.5中都已经被抛弃,不推荐使用了。
 
一派掌门 二十级
4楼 发表于:2015-5-31 12:19
 robertpas550 at hotmail dot com ¶
3 years ago
New users are advised to use MySQL Improved mysqli_ functions rather than the older [replaced] mysql_ functions where applicable and subject the appropriate latest stable versions of Apache, php and MySQL, etc.

 
一派掌门 二十级
5楼 发表于:2015-5-31 12:21
所有的mysql扩展页面都挂上了醒目的红框框:
Warning
This extension is deprecated as of PHP 5.5.0, and will be removed in the future. Instead, the MySQLi or PDO_MySQL extension should be used. See also MySQL: choosing an API guide and related FAQ for more information. Alternatives to this function include:

    mysqli_affected_rows()
    PDOStatement::rowCount()

 
UTC+13:00
張樹人
初级工程师 九级
6楼 发表于:2015-6-1 10:49
我们参考书上是讲用mysqli,老师课上讲用PDO
 
一派掌门 二十级
7楼 发表于:2015-6-1 12:18
mysqli也是物件导向的php库。
而MySQL仅仅是一对函数,虽然c语言里面也是这些函数。
 
一派掌门 二十级
8楼 发表于:2015-6-1 12:19
刚开始用MySQL的时候我很不习惯,因为是字符控制台界面的。但现在我倒是觉得比Microsoft access好太多了。
 
一派掌门 二十级
9楼 发表于:2015-6-1 12:26
mysqli在国内的某本书上介绍过。
 
一派掌门 二十级
10楼 发表于:2015-6-4 22:56
其实MySQLi库我只用过一次
2010.7那次
 

回复帖子

内容:
用户名: 您目前是匿名发表
验证码:
(快捷键:Ctrl+Enter)
 

本帖信息

点击数:1413 回复数:9
评论数: ?
作者:巨大八爪鱼
最后回复:巨大八爪鱼
最后回复时间:2015-6-4 22:56
 
©2010-2025 Purasbar Ver2.0
除非另有声明,本站采用知识共享署名-相同方式共享 3.0 Unported许可协议进行许可。