Andrew Nacin
82bc9c1142
Rename USE_EXT_MYSQL to WP_USE_EXT_MYSQL. see #21663 .
...
git-svn-id: https://develop.svn.wordpress.org/trunk@28022 602fd350-edb4-49c9-b593-d223f7449a82
2014-04-07 22:26:19 +00:00
Drew Jaynes (DrewAPicture)
aba414af7e
PHPDoc fixes for functionality in wp-includes/wp-db.php added in 3.9.
...
See #27700 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28016 602fd350-edb4-49c9-b593-d223f7449a82
2014-04-07 22:01:37 +00:00
Andrew Nacin
f9e150c068
wpdb: Don't pass a second argument to mysqli_fetch_field().
...
props pento.
fixes #27693 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28002 602fd350-edb4-49c9-b593-d223f7449a82
2014-04-07 20:21:16 +00:00
Andrew Nacin
ccb4f3714a
Database: Fall back from ext/mysqli to ext/mysql if the connection fails.
...
This allows us to avoid breaking a site that works under ext/mysql but is misconfigured for ext/mysqli.
props pento.
see #21663 .
git-svn-id: https://develop.svn.wordpress.org/trunk@27935 602fd350-edb4-49c9-b593-d223f7449a82
2014-04-03 21:57:22 +00:00
Andrew Nacin
0faaacc7c8
Database: Add $allow_bail argument to wpdb::check_connection() to match the connect method.
...
props DrProtocols, pento.
fixes #27240 .
git-svn-id: https://develop.svn.wordpress.org/trunk@27925 602fd350-edb4-49c9-b593-d223f7449a82
2014-04-03 04:05:31 +00:00
Sergey Biryukov
28dd458547
Avoid a warning in wpdb::db_connect(). before_needle parameter of strstr() was added in PHP 5.3.
...
props klihelp, pento.
fixes #27277 .
git-svn-id: https://develop.svn.wordpress.org/trunk@27503 602fd350-edb4-49c9-b593-d223f7449a82
2014-03-11 19:26:02 +00:00
Andrew Nacin
79143bfed1
Make OBJECT a case sensitive constant, for HHVM compatibility and general sanity.
...
Support `object` explicitly, and other forms using a fallback in wpdb.
fixes #27231 .
git-svn-id: https://develop.svn.wordpress.org/trunk@27377 602fd350-edb4-49c9-b593-d223f7449a82
2014-03-03 17:35:12 +00:00
Andrew Nacin
f3a23fb43f
Reference https://wordpress.org rather than http://wordpress.org in strings, links, comments, etc.
...
props Ipstenu, markjaquith.
see #27115 .
git-svn-id: https://develop.svn.wordpress.org/trunk@27369 602fd350-edb4-49c9-b593-d223f7449a82
2014-03-03 02:33:24 +00:00
Andrew Nacin
544b73ec4c
When failing to reconnect to a server that has gone away, simply fail the query once we've passed template_redirect, rather than wp_die().
...
props pento.
see #5932 .
git-svn-id: https://develop.svn.wordpress.org/trunk@27279 602fd350-edb4-49c9-b593-d223f7449a82
2014-02-26 04:53:21 +00:00
Andrew Nacin
73ad0a310a
Add a constant to disable mysqli for testing purposes. see #21663 .
...
git-svn-id: https://develop.svn.wordpress.org/trunk@27278 602fd350-edb4-49c9-b593-d223f7449a82
2014-02-26 04:19:45 +00:00
Andrew Nacin
b84ed60fa9
wpdb: set dbh to null when the mysqli connection fails. see #21663 .
...
git-svn-id: https://develop.svn.wordpress.org/trunk@27277 602fd350-edb4-49c9-b593-d223f7449a82
2014-02-26 04:14:54 +00:00
Andrew Nacin
19d7d1dd09
Use mysqli for WordPress development versions, regardless of PHP version, to increase testing footprint.
...
Allow the lack of ext/mysql to pass wp_check_php_mysql_versions().
see #21663 .
git-svn-id: https://develop.svn.wordpress.org/trunk@27257 602fd350-edb4-49c9-b593-d223f7449a82
2014-02-25 15:52:48 +00:00
Andrew Nacin
f8af178264
Use ext/mysqli in PHP 5.5 or greater. Expect minor explosions.
...
props aaroncampbell, pento.
see #21663 .
git-svn-id: https://develop.svn.wordpress.org/trunk@27250 602fd350-edb4-49c9-b593-d223f7449a82
2014-02-25 00:39:28 +00:00
Andrew Nacin
c61accb146
Declare $wpdb->base_prefix.
...
props DavidAnderson.
fixes #16762 .
git-svn-id: https://develop.svn.wordpress.org/trunk@27249 602fd350-edb4-49c9-b593-d223f7449a82
2014-02-25 00:29:01 +00:00
Drew Jaynes
b013aaf4c9
Fixes for hooks documentation in wp-includes/wp-db.php.
...
See #26869 , #25229 and [25284].
git-svn-id: https://develop.svn.wordpress.org/trunk@27147 602fd350-edb4-49c9-b593-d223f7449a82
2014-02-09 20:50:42 +00:00
Andrew Nacin
194d6a94b7
When the MySQL server has "gone away," attempt to reconnect and retry the query.
...
props pento.
see #5932 .
git-svn-id: https://develop.svn.wordpress.org/trunk@27075 602fd350-edb4-49c9-b593-d223f7449a82
2014-02-02 22:06:42 +00:00
Andrew Nacin
e993ef0249
Add a comment for [27073] as someone will inevitably complain it is tricked by % in a string. see #25604 .
...
git-svn-id: https://develop.svn.wordpress.org/trunk@27074 602fd350-edb4-49c9-b593-d223f7449a82
2014-02-02 21:47:58 +00:00
Andrew Nacin
435df55864
Throw an incorrect usage notice when the query argument of wpdb::prepare() does not include a placeholder.
...
props ounziw.
fixes #25604 .
git-svn-id: https://develop.svn.wordpress.org/trunk@27073 602fd350-edb4-49c9-b593-d223f7449a82
2014-02-02 21:46:07 +00:00
Andrew Nacin
0558df56ce
Ensure compatibility with MySQL 5.6 which has stricter SQL modes by default.
...
Disables NO_ZERO_DATE, ONLY_FULL_GROUP_BY, STRICT_TRANS_TABLES, STRICT_ALL_TABLES, TRADITIONAL. Introduces wpdb::set_sql_mode() with an incompatible_sql_modes filter so a plugin can alter the set mode after the fact.
props pento.
fixes #26847 .
git-svn-id: https://develop.svn.wordpress.org/trunk@27072 602fd350-edb4-49c9-b593-d223f7449a82
2014-02-02 21:38:34 +00:00
Scott Taylor
62b57d8899
In wpdb::db_connect()
, allow the loading of a custom database error template - this is already allowed in dead_db()
.
...
In `dead_db()`, move the call to `wp_load_translations_early()` before the inclusion of the `db-error.php` file to allow translation in both locations before the template is loaded.
Props sbruner, kovshenin.
Fixes #25703 .
git-svn-id: https://develop.svn.wordpress.org/trunk@27056 602fd350-edb4-49c9-b593-d223f7449a82
2014-01-29 05:27:24 +00:00
Scott Taylor
50edc63cc9
When WP_DEBUG
is set to true
, suppress deprecated errors from firing when calling mysql_connect()
, which is officially deprecated in PHP 5.5. We will remove this shameful code as soon as is humanly possible.
...
Props wonderboymusic. Extra love to tierra and nacin.
Fixes #26322 .
git-svn-id: https://develop.svn.wordpress.org/trunk@26512 602fd350-edb4-49c9-b593-d223f7449a82
2013-12-02 00:08:57 +00:00
Andrew Nacin
8a0ac73f60
Document the 'query' filter in wp-db.
...
props natejacobs.
see #25229 .
git-svn-id: https://develop.svn.wordpress.org/trunk@25284 602fd350-edb4-49c9-b593-d223f7449a82
2013-09-06 17:07:00 +00:00
Andrew Nacin
b43712e0f7
New develop.svn.wordpress.org repository based on the old core.svn repository.
...
* All WordPress files move to a src/ directory.
* New task runner (Grunt), configured to copy a built WordPress to build/.
* svn:ignore and .gitignore for Gruntfile.js, wp-config.php, and node.js.
* Remove Akismet external from develop.svn. Still exists in core.svn.
* Drop minified files from src/. The build process will now generate these.
props koop.
see #24976 .
and see http://wp.me/p2AvED-1AI .
git-svn-id: https://develop.svn.wordpress.org/trunk@25001 602fd350-edb4-49c9-b593-d223f7449a82
2013-08-07 05:25:25 +00:00