简体   繁体   English

我应该从Zend_Db移植到哪个本地mysql类? (没有PDO或Mysqli)

[英]What native mysql class should I port to from Zend_Db? ( No PDO or Mysqli )

I'm dealing with a client who has a legacy cPanel account where the php installation was not compiled with PDO nor Mysqli therefore my Zend_Db code is useless since it relies on either of those. 我正在与一个具有旧cPanel帐户的客户端打交道,该客户端的php安装未使用PDOMysqli编译,因此我的Zend_Db代码是无用的,因为它依赖于这两个代码。

What library/class should I go with? 我应该使用哪个库/类?

Depends what you're trying to achieve, it's possible to extend Zend Frameworks Zend_Db and add a mysql adapter. 根据您要实现的目标,可以扩展Zend Frameworks Zend_Db并添加mysql适配器。 If this is too much trouble there are two library's that are probably worth looking at, the first depends on PEAR being installed and is MDB2 the other is ADOdb both offer OO DB abstraction and work with the mysql extension. 如果这太麻烦了,那么可能有两个库值得一看,第一个库依赖于PEAR的安装,是MDB2 ,另一个是ADOdb,它们都提供OO DB抽象并与mysql扩展一起使用。

机智-我刚刚制作了自己的类,模仿了Zend_Db的确切方法和功能,因此不必重新编程很多代码。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM