Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

WordPress stores user generated content, along with other configurable information, in a database (typically MySQL).

0
votes
1answer
10 views

Duplicate database to roll back theme & content changes

I am going to update site to a new custom theme and it will take a few days to get all the work done. Can I duplicate a wp database in phpMYadmin, so i have wp-db1 and wp-db2. Then I can change wp-...
0
votes
0answers
23 views

Custom post type - Huge DB - $query->set

I display some custom tables (backend) for my custom posts type. I have created many upstream filters, let's take the following example : First custom post type : bank_accounts Second custom post ...
0
votes
0answers
11 views

How to map data on CSV to web pages?

Like Contact information, descriptions, budget, prices, other numbers, on a CSV or spreadsheet, how to link it to WordPress web page? I'm using cpanel, WordPress, Tablepress plugin, elementor page ...
0
votes
0answers
13 views

Updating Posts table in database without overwriting user generated content

I'm trying to come up with a local development workflow for wordpress that actually works. I'm pretty new to this whole thing but I'm surprised this is so complicated. So far I've been using Git and ...
0
votes
0answers
14 views

Lost connection to MySQL server during query?

I am very curious to know if anyone has seen this error, know what is generating this errors, and if so, how to remove it? It is happening while trying to query a woo commerce product in the serch ...
0
votes
3answers
50 views

WordPress credentials not matched

Ok, I'm at wit's end with Wordpress. This is the fifth time I've tried installing it and it flat out is not working. When I install it, it shows one of the themes, but the default welcome post doesn'...
0
votes
0answers
7 views

Is there any service that I can automatically get an updated mysql in my local machine from online?

This is how I do to keep my local machine and my online version of Wordpress php files same as that of each other. Git to repository (either bitbucket or GitHub) Set a deployment service to the ...
0
votes
0answers
5 views

Multisite Search by custom taxonomy

With multisite, each blog has its own table. I want to create a plugin that will add custom taxonomies to all blogs. I know how to do this. Then I want to create a query to return all posts for a ...
0
votes
0answers
33 views

Automatically restore the last backups for demo purpose

let me explain what I want to achieve: I will use my site to be a demo for my premium themes for ThemeForest to allow anyone to add, edit posts and comments, Now I want a way to automatically restore ...
-1
votes
0answers
11 views

user registration from application android studio

user registration from application android studio how i can regitre user from android application to my site wordpress programmatically,so can you help me i like to make application with native ...
1
vote
0answers
15 views

How to remove traces from widget during uninstallation

I have a small plugin, which registers a custom widget and now I am wondering how to remove all traces of this widget when the plugin is removed through the administration. If I look in the database ...
0
votes
0answers
16 views

How to clean out old/unused pages?

We've got a WordPress site that has been running for over 10 years and is closing in on 1,000 pages. We know there are quite a few pages that haven't been accessed in a long time and we'd like to get ...
1
vote
0answers
14 views

Create a database for each site created in multisite?

I am running a multisite network and I want to be able have each new subsite to have it's own database instead of 1 big database. Is there a way to make it whenever I create a new subsite it should ...
0
votes
1answer
20 views

Alter the cost of products using phpmyadmin sql query

What is the SQL query can i use in phpmyadmin to alter(update) the listed products cost in woocommerce. EX: I want to add or subtract $100 from all the listed products.
-2
votes
0answers
18 views

Single database For multi use Wordpress site

I would like to create a site where the user can register and then under that one registration they can purchase things from the shop on the website, use the market place on the website and use the ...
0
votes
1answer
22 views

Moving my site from localhost to server - too many redirects

I want to move the site I was working on on localhost to a testing server. I have copied the database over as well as all the files. I want to be able to run my site from the testing server with the ...
0
votes
0answers
18 views

Why does the correct MySQL “UNIQUE Key” syntax not work in the dbDelta function?

this is the working Mysql code CREATE TABLE customtable ( id mediumint(9) NOT NULL AUTO_INCREMENT, email text NOT NULL, emailverifytoken text NOT NULL, UNIQUE Key (email(255)), UNIQUE Key (...
1
vote
4answers
40 views

If I delete plugins via FTP are settings kept in DB?

When I delete plugins via ftp (meaning all its files recursively) does WordPress remove its settings from the database? I want to delete all plugins on one of my websites and reinstall them, since I ...
0
votes
0answers
43 views

Multi-Dimensional Array Get Column

At the moment the query below does what it should, queries a questions table for a series of questions and the looks for the corresponding answers from another table depending on a submissions id. It ...
4
votes
2answers
201 views

Lost the `wp_options` table: what's the best way to restore the site?

Due to some important hardware failure, the wp_options table of one of my WP sites became corrupted, but everything else is okay (WP files and other tables). Obviously the site does not work because ...
0
votes
0answers
16 views

Share a single database or multiple databases

I currently have a live site on its own database (prefix wp_). I want to install a new region-specific site on subdirectory (e.g. domain.com/my). The blog will always be on the first site (domain.com/...
0
votes
1answer
20 views

Create table with dbDelta,can't put any DEFAULT data

I want to add more custom tables to wp_users. but I want them to contain a default JSON data. This one works...when the DEFAULT is empty... register_activation_hook(__FILE__, 'toto_user_db_setup')...
-1
votes
1answer
24 views

Most efficient way to get custom database records from 20 buttons and 20 tables?

I have 20 buttons on a member protected wordpress page and each button gets a random record from a different custom table in the wp_ database. @janh provided a solution here to get the random record ...
0
votes
1answer
23 views

How to Access custom database content with AJAX onClick refresh of div inside member-only wordpress page?

The use case is providing the user with 20 different buttons on a single login protected page, each button is a category from a custom database table and the content is shown in a textarea element on ...
0
votes
0answers
24 views

Notification for users based on saved search queries

I have been working on a saved search functionality and it's almost complete, I just need help with the very last part of the equation. I was able to run a wp_query which checks the found_posts of a ...
0
votes
0answers
87 views

PHP message: WordPress database error Deadlock found when trying to get lock

I'm trying to fix this deadlock issue on my site without luck. I'm using WordFence and when I disable it, the error is gone. I disabled the plugin by removing it completely and reinstall it again, but ...
0
votes
0answers
19 views

WordPress WP_User_Query fail on large number of users available in database

We have an issue with WP_User_Query with huge database. Let me explain it. We have 147000 users with role "professional" under a category doctors in our database and when we apply search on database ...
0
votes
2answers
34 views

How to print array of specific item

I have get the following array from my database using mysql query in PHP. What is way to print the specific item (e.g: staff_name and coupon)? {"items":[{"ca_id":1,"appointment_date":"2018-07-02 08:...
0
votes
1answer
17 views

custom search query database in child theme

I am trying to display searched data from database in wordpress child theme. It does work on localhost but when I apply the code in wordpress only Warning: Invalid argument supplied for foreach() ...
0
votes
1answer
20 views

WordPress database error: [Table 'wordpress.wp_transients' doesn't exist] SHOW FULL COLUMNS FROM `wp_transients`

This is the error message: WordPress database error: [Table 'wordpress.wp_transients' doesn't exist] SHOW FULL COLUMNS FROM wp_transients This error is displayed to me on every page I open and this ...
0
votes
0answers
13 views

Access the external mySQL database to create, update and delete users though forms on WordPress pages

I have looked around for a WordPress Plugin to manage a divergent group of users. There are three types of users and each of them has a different registration requirement. By using the “standard” ...
0
votes
0answers
16 views

Importing Posts and galleries with ids but galleries look broken

I want to move posts from my old blog to new one which has a few images and posts already. (My new blog relies on a lot of plugins. Other way just won't work.) I want to import the posts. (importing ...
0
votes
1answer
20 views

Error at time of Wordpress Installation

Following error accure at the time of installation. Please help WordPress database error: [Error on delete of 'C:\xampp\tmp#sql894_b5_31.MYD' (Errcode: 13 - Permission denied)] SHOW FULL COLUMNS ...
0
votes
0answers
14 views

Slow Query On Search

Please I have a very slow query on my wordpress search, checking the processes it takes upto 40sec to execute using SHOW FULL PROCESSLIST; below is a sample of query SELECT SQL_CALC_FOUND_ROWS ...
0
votes
0answers
31 views

How to properly check if a table exists in WordPress Database using Show Tables Query

This query when runs always create logs for Database error. It works fine when table exists, but when it does not it generates the below shown debug logs. Any alternative way to check if database ...
0
votes
1answer
27 views

wp-login.php?redirect_to=https problem

wp-login.php?redirect_to=https problem Please forgive me if I am posting in the wrong place but I am here to see if you can help me with some minutes of your time. The problem is a website showing ...
0
votes
0answers
25 views

Custom Login Integration not working in wordpress anymore

I have added a script in my functions.php file which checks a second custom database within the WordPress database when a member tries to login. This script was working correctly in the past and I ...
0
votes
2answers
50 views

Show data from one Custom Post Type in another Custom Post Type

I'm working on a project where we'll be creating two different custom post types: Machines and Enquiries. The Machines posts will be created by admin, and will simply be a list of items that are for ...
0
votes
1answer
28 views

Delete/Replace words from X to Y in post content

I am looking for a way to search and replace some words in my database. I have many posts on one of my blog and i want to replace words using regexes. before publishing, I marked every place I wish ...
0
votes
1answer
45 views

How can I store user preferences in WordPress and retreive them later?

I have a WordPress website where I want to give users some options to sepcify how they want to see the site. For example, they can choose from a given set of fonts, menu color etc. I am assuming this ...
0
votes
1answer
14 views

Wordpress Database Cleanup

How hard would it be to rebuild a WordPress database and change the directory structure for a website? I inherited the maintenance of two websites and I am pretty sure the directory structure is set ...
0
votes
1answer
41 views

WP website showing blank page after moving from subdomain to main domain

I created my website on the subfolder https://www.lokaction.be/dev/. After it was finished, I moved the website's files to the main adress https://www.lokaction.be/ (ftp). And after that, I edited ...
1
vote
3answers
67 views

Is it possible to create a wordpress database with php code?

Just curious . Is it some how possible to create a database with php code? I am having only having access to public_html folder and i want to make a wordpress installation. Is there any method to make ...
1
vote
0answers
108 views

How to merge two WordPress databases with the same structure?

I have two WordPress sites with the same database structure (same prefix, number of tables etc.). Now I want to merge all data from the two databases to make it one single database. How can I do that?...
2
votes
1answer
23 views

Wordpress register_activation_hook table creation not working

I've created a simple Class for my wordpress plugin. The main file looks like this: <?php /* * Plugin Name: Codes * Description: Generates a coupon code after checkout * Version: 0.1.0 * ...
1
vote
1answer
43 views

Use Wordpress MultiSite (WPMS) with a remote database for each created site

So, I am interested in really figuring out a way to use WPMS with different remote databases for each new sub-site added. What I know. I know that a remote database can be on it's own server to allow ...
8
votes
3answers
1k views

MariaDB as a backend database

I know WordPress expects to use MySQL as it's database backend, but can I switch to using MariaDB instead? MariaDB is a fork of MySQL that includes a bunch of really nice improvements for ...
0
votes
0answers
20 views

Customizer settings do not transfer from dev to staging

I'm running a local dev server and a staging server for my site. After pushing to remote, the customizer settings are all lost. I am using the underscores theme with one added custom text area in inc/...
0
votes
0answers
83 views

WP_Term_Query->get_terms() very slow query for WordPress filter

My first site is almost done, but I am unhappy with how slow the filter-drop downs are populating. My site is for auto-parts so I have many categories with sub categories (Parts -> Type -> Make -> ...
1
vote
0answers
12 views

Update results, Before deleting the related category [closed]

There is a DB that contains 2 tables posts and categories, Each category could contain many posts, So I'm using one-to-many relation between the two tables. Using the id of the categories and a ...