[wp-trac] [WordPress Trac] #21663: Use PDO or mysqli for MySQL queries when available
WordPress Trac
noreply at wordpress.org
Tue Feb 25 17:03:36 UTC 2014
#21663: Use PDO or mysqli for MySQL queries when available
------------------------------+------------------
Reporter: scottconnerly | Owner:
Type: task (blessed) | Status: new
Priority: normal | Milestone: 3.9
Component: Database | Version: 3.5
Severity: normal | Resolution:
Keywords: has-patch commit | Focuses:
------------------------------+------------------
Comment (by bpetty):
Replying to [comment:200 nacin]:
> `USE_EXT_MYSQLI` means if we ever add PDO, we would need to continue to
force MySQLi in order to obey their settings. It would be a permanent
fixture. An ext/mysql constant, however, would eventually just fade away.
This is a good idea.
Would the code for switching to mysqli in development versions also
disappear during RC or code freeze? Just curious since it would mean the
unit tests would also always use mysqli across the board (including with
PHP 5.2), which will be great for testing, but leaves us without results
on ext/mysql all the way up to the very final tagged release even though
it's still going to be used with 99% of installations right now. I'm not
really too concerned about it, but it's something to think about.
> For this situation, said hackers should update to PHP 5.5. If they want
to use a more modern library, then the onus should be on them to use a
more modern version of PHP.
Completely agreed here. If there's actually anyone in a situation where
they could legitimately use mysqli enhancements or optimizations, the
choice of upgrading to PHP 5.5 should make much more sense anyway, and
they most likely already have the power to do this on their server(s). I'm
honestly having a hard time even coming up with some use cases that might
cover more than even 0.1% of users, and for that many, installing a DB
drop-in is still a perfectly acceptable solution.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/21663#comment:203>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list