Home > WordPress > Quick hack: MySQLi support for WordPress 2.0.5

Quick hack: MySQLi support for WordPress 2.0.5

December 29th, 2006 Leave a comment Go to comments

I wrote this quick hack to enable mysqli calls on WordPress. I prefer using mysqli on all my projects, and typically look change the packages I use to use it as well. I was surprised to see WordPress didn't use some bundled database abstraction layer; although those typically create more overhead, with such a large userbase I thought it would be in there. Oh well.

It wasn't very difficult, and seems to work 100% so far (how do I know? You're using it right now!)

Patch file:

Apply with: "patch -p0 -u < wordpress-2.0.5-mysqli.patch.txt" in the WordPress install directory.

Any comments? Feel free to share! Note: this is the first patch I've created, bear with me while I learn 🙂

(Reposted from the my post on the WordPress forum)

According to someone on the forum, there may be an easier way to do it soon just by supplying a different PHP file. However, for now, it is still easiest to just apply the patch.

Categories: WordPress
  1. No comments yet.
  1. No trackbacks yet.
You must be logged in to post a comment.