New answers tagged

0

You may use this WordPress user import export plugin to migrate to your user including their password. Tested OK with WordPress 5.2


4

General speaking yes for read-only applications (until MySQL 5.7, it's deprecated since version 8.0), it enables equal SELECTs to return data extremely fast if identical calls are already stored in cache. You should consider that: Only exact same clauses can benefit from the cache engine (no spaces, no comments, no actual differences in WHERE expressions); ...


0

It is likely there are very few rows WHERE AND ( wp_posts.post_date >= '2019-09-04 21:45:00' ) there are likely many thousands of rows WHERE AND ( wp_posts.post_date < '2019-09-04 21:45:00' ) and a table scan is required. EXPLAIN SELECT SQL_NO_CACHE remainder of query for each and examine results carefully.


0

The post thumbnail is not stored as a URL. The post thumbnail is stored as the attachment ID in the _thumbnail_id post meta. The actual file is stored as the _wp_attached_file post meta for that attachment post. WordPress does not store the full URL for attachments in the database. It only stores the path to the file, relative to the uploads directory. This ...


0

You'll find details here: https://gist.github.com/lukecav/05afef12feaf980c121da9afb9291ad5 OR Another approach is https://github.com/woocommerce/woocommerce/wiki/wc_get_orders-and-WC_Order_Query . Use if....else and store order data in Arr[product_id] = OrderArr Kindly accept my answer if it is of any help.


0

this is actually the same method I follow when I'm about 60-80% complete with the total theme build. it allows my client (or my co-workers) to work on the content and update the pages and thus the database on the staging server while I continue working locally on other custom page development, templates, etc. the only downside I've experienced is that it ...


0

Wordpress, and many of its plugins, store configuration data in the database. That alone could cause issues for the setup you described, but the urls of every link will also be stored fully canonicalized. So, unless you plan to test your staging setup from "http://localhost", you will have serious issues trying to click around multiple resources for ...


0

the solution was to set the host as localhost:3307 not just localhost. Like so https://gyazo.com/3aa87d040d9953171da69b196d04f4d1


0

If I correctly understood, this is not possible (two queries instead of one). I ended up with this sad and time-consuming loop... :/ //get subtracks $querystr = $wpdb->prepare("SELECT subtrack_id FROM `$subtracks_table` WHERE tracklist_id='%d' ORDER BY `subtrack_time` ASC",$this->post_id); if ( !$ids = $wpdb->get_col($querystr) ) return;...


0

As Pat J says, you shouldn't have define( 'WP_USE_EXT_MYSQL', true); unless you need the old mysql functions, which you do not if you're using PHP 7x and WordPress 5x. You do need to restart Apache after modifying php.ini. What do you have in your mysqli section of your phpinfo? Make sure extension_dir is set in php.ini, too. You may need to enable php.ini ...


Top 50 recent answers are included