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

learn more… | top users | synonyms

0
votes
0answers
9 views

Function to retrieve IDs of posts, cache results, and improve wp_query

I'm looking to optimize db performance by creating a function that retrieves IDs of posts in a certain category and caches results. So instead of having a query like: SELECT … WHERE 1=1 AND ...
1
vote
1answer
11 views

Can I store my custom comment_type into wp_comments table?

I'm developing a system where a post can have multiple replies/feedbacks. As of now I's storing each of the comments as a serialized postmeta. But just today I figured out that I can use the existing ...
0
votes
1answer
10 views

WordPress and SQL - Update and Insert from another table if column value doesn't exist

Stuck with some mysql for my wordpress site. All within 1 DB. I am attempting to update wp_options table from wp_2_options (Multisite). They both have option_name (unique_key) and option_value ...
0
votes
1answer
32 views

Deleted my Wamp database… Website is gone [on hold]

I had some problems with FileZilla and WAMP server to host my website and after 18 hours of searching all around the internet I finally deleted WAMP to reinstall it... Unfortunately, being a complete ...
2
votes
6answers
2k views

Multisite database upgrade SSL error

I have upgraded my Multisite setup WordPress to 3.6.1. And after that, when I do Network Upgrade > Database Upgrade it's showing: Warning! Problem updating http://www.example.com/site1. Your ...
0
votes
1answer
22 views

live site do not update after importing sql database

My live website is not updating after importing sql database from wamp local server until last time all went perfect but last night I was not able to see the changes live made in local. what I did: ...
1
vote
1answer
288 views

Database location in Wordpress

I have created my website in WordPress and want to transfert it in my domain created with ipage. I am not able to locate the WordPress database. Can you help me? How is the format or extention of DB ...
0
votes
0answers
14 views

count click on link class on posts and add it to custom field

I have 4 links on each of my posts (facebook, twitter, etc ...), what I'm trying to do, is that everytime someone click on one of this link, i'll have a counter incremented, and store the reslut in a ...
0
votes
2answers
25 views

Deleting a category from WordPress admin does it remove it completely from the database?

When you delete a category in the admin of WordPress does it completely remove it from the database? I had a few categories with the same naming conventions (different slugs) but now deleting any ...
0
votes
0answers
10 views

How to import wp_options rows from Wordpress admin?

Is there any plugin, script or solution to importing rows from wp_options into another Wordpress site via the Wordpress admin? For example import a .sql file that has the rows needed that upon ...
-1
votes
0answers
10 views

Categories Disappearing from front-end [closed]

I am using Woocommerce version 2.3.8 and am having trouble with my categories. My problem is when I add a product to a category it makes the entire category disappear from the front-end of my ...
0
votes
1answer
20 views

Embed a Google Sheet as you view it in a separate tab?

Is it possible to embed a Google Sheet as you view it in a separate tab like in this website? I have tried to use Publish to the web or the plugin Inline Google Spreadsheet Viewer but it just embed ...
0
votes
1answer
20 views

Error message on blog posts only on my local environment [closed]

I copied all my WP files from the server to my local WAMP as a dev-environment. Everything works smoothly except when viewing a blog post. I get a good output of all the ...
0
votes
5answers
989 views

I have a 1300 line excel spreadsheet that needs to get into a wordpress site ASAP - Looking for ideas

I have an excel spreadsheet that needs to get on a WP site PDQ and IE is choking on it. I tried making an html table, but it's huge. I looked into some kind a database plugin that would let me ...
0
votes
1answer
599 views

#1273 - Unknown collation: 'utf8mb4_unicode_ci' [closed]

I'm trying to migrate my site from hostgator to local windows on desktopserver - and when I try to import the database I get this error: 1273 - Unknown collation: 'utf8mb4_unicode_ci' I've been ...
0
votes
1answer
541 views

Retrieve and display data from custom db table in admin area?

So, i'm having a bit of an issue with a plugin i'm developing, I wonder if anyone can shed any light on the situation, as many, MANY searches have come back with zero help. :-/ Basically, my plugin ...
-4
votes
0answers
21 views

Can Wordpress work separate databases? [closed]

I am now facing a problem that I need to create a wordpress site that works with 3 separate databases together? Can anyone give me some tips to solve it?
-1
votes
1answer
104 views

Resolving following issue [closed]

Error SQL query: -- -- Database: wordpress -- -- -------------------------------------------------------- -- -- Table structure for table wp_commentmeta -- CREATE TABLE IF NOT EXISTS wp_commentmeta ( ...
0
votes
3answers
43 views

How to intercept update_option() before it saves data?

I am working with redux framework and need to save theme option values to a file right before it is saved in DB. Is there a way to intercept update_option() right before it saves data in DB?
0
votes
1answer
14 views

Sending WordPress database information to cross domain the safe way?

I want to send my options and WP_user database information to my AWS server from my WP site's database. I heard using PHP'cURL is not recommended. I want a safe solution so please aid me in the right ...
0
votes
2answers
45 views

Inserting dynamic content into a page

I see this subject comes up regularly but have not seen an answer to my specific requirement yet. I'm trying to use a WordPress page as a template and insert database-sourced content (about 20 or so ...
0
votes
1answer
19 views

Transforming an wp_options database array into a javascript obect?

In my WP code I grab my options information as such $options = get_option("kaipo_plugin_options"); The array that I print out looks as follows ...
0
votes
0answers
12 views

How to show same posts on different WordPress installs?

I have 2 websites using WordPress on the same server and the same database with spesific prefixes. I want to show the posts of the first site in the second site. For example: I have 100 posts in ...
3
votes
2answers
240 views

Detecting errors generated by $wpdb->get_results()

How do I detect errors when using $wpdb->get_results()? For example: $result = $wpdb->get_results("SELECT * FROM this is not a valid query"); The preceding code doesn't generate any exceptions ...
0
votes
1answer
29 views

i can not access my local host, when i look in phpadmin my databases are gone and i am unable to login to mysql [closed]

I am absolutely terrified that I will have to rewrite my entire website. Please help me! I have a copy of my database, I exported it and saved it on an external hard drive. This is my first time ...
2
votes
2answers
31 views

Shared table across network

Im currently creating a plugin that will read an xml file and import the data into 4 tables on a wordpress multisite. the tables are rather large, with ALOT of columns, so the post table is not ...
0
votes
1answer
26 views

Can not manually create a database ( db, user, pass ) for a plugin

So I was working on a plugin and I needed to cache some third party API access, and I needed to manually create a database upon plugin activation or upgrade. The caching stuff needs a database host ( ...
0
votes
1answer
19 views

how to read database fields

Can someone please explain how to read the letters, numbers, and colons in the wordpress database? For example: a:1:{s:13:"administrator";b:1;} in the wp-capabilities table. Thanks!
0
votes
1answer
304 views

Is there any way to recover deleted menu from database sql backup

i accidently deleted my main menu but i have a .sql database backup file and i want to recover my menu from this file. Is it possible? Thanks.
1
vote
1answer
750 views

Wordpress database import: Row size too large

I've done a dump of my Wordpress database using Windows's command prompt: mysqldump -u username -p databasename > filename.sql Then, on a different server, imported it using: mysql -u username ...
0
votes
1answer
22 views

Media library images “missing” after migrating them using SQL

I am migrating a lot of posts from an old site to a new site, and these posts have a lot of Advanced Custom Field "relationship" data attached to them. Because of this, I want to keep all of the ids ...
6
votes
3answers
6k views

DB connection error after copying a WordPress Multisite instance to a second location

Here's my setup. I have a Multisite instance running at http://example.com, and I want to do development and staging. Moving an existing Multisite instance of WP onto localhost is a nightmare, so I'm ...
0
votes
2answers
276 views

Error establishing a database connection - Multi-site with subsite don't exisit [duplicate]

I have a multi site setup to which I have placed define( 'NOBLOGREDIRECT', 'http://www.example.com' ); In the wp-config.php file However when I visit a site which dose not exist (e.g. ...
0
votes
2answers
1k views

Saving Custom Post types and fields to a custom table

I have a project in which I am trying to import a large amount of data into a WordPress installation and from that data, create pages on my site (as a custom post type). Since these pages will be ...
2
votes
1answer
2k views

Insert query inserts 2 entries, should insert 1

I've written a small posts by views plugin, well at least started one. My tables are set up but when they are updated the code adds 2 entries into my table when a post is loaded and views are ...
0
votes
0answers
19 views

Passing string from a form to another page [migrated]

I have tried several plugins to try and pass a text field to another page via PHP and a HTML form. The form works and displays what was entered if there are no text input boxes in the form. The end ...
1
vote
4answers
4k views

Converting WordPress into Android or iPhone app

I've had a request from my client to convert their WordPress website into an App for Android and iPhone. I've looked around at a number of options and it seems doable especially for just the blog ...
5
votes
2answers
3k views

Count & Display Database Queries

I'm looking for an solution how I can count and display all queries in a WordPress site. Does anybody know, if there is an good plugin? Otherwise it would be an solution to check the queries on the ...
3
votes
2answers
920 views

Shared Members between two different wordpress installations with different databases

I have two wordpress installations with same host with different folders. Each installation uses its own database. I mean, database are separated. I am not using one database for two wordpress ...
0
votes
1answer
348 views

Displaying BLOB PDF File

I have some pdf files that are stored in the wordpress database as a blob and I need to display these files. The files are not linked to any posts directly. The code I have currently is: <div ...
0
votes
1answer
9 views

Include plugin form in the home page

I created a Wordpress plugin, which allows the admin to add information through a form, and it is saved in the database. I'm trying to link each photo that I upload in the Media library with a form. ...
0
votes
1answer
4k views

Error establishing a database connection when installing multiple sites locally

Initially I was using MAMP and had only 1 wordpress site running locally on my Mac. I've set: document root to: documents/mywebsites/mysite1 In phpMyAdmin I created a DB called: mysite1 wp-config ...
4
votes
3answers
425 views

Why WordPress choose data serialization over json_encode?

In my little age with WordPress, I've seen WordPress itself and its friendly plugins are using PHP serialize() in storing data into db in many cases. But in a recent search I found a serious community ...
1
vote
1answer
46 views

Get data from database using $WPDB

I'm missing something here. I simply want to get data from my database. So I tried this but keeps giving me an error. global $wpdb; $sql = "SELECT * FROM $wpdb->postmeta WHERE group='$group'"; ...
0
votes
1answer
376 views

Safely store code(html/js..) into database

So I'm working on a small plugin, and this plugin allows users to save data to my db. This data is mostly plain text but 3 fields are will have tags inside them. 1 field can be used to save all kind ...
1
vote
1answer
382 views

Wordpress choose wrong database

I have 2 databases. When I include the database connection (with a include('filename.php');) wordpress acts really strange. I can't login, the wordpress username and password is right but it tries to ...
3
votes
4answers
2k views

How to run Two Wordpress blogs with different themes and with single database and same content

How do you run two Wordpress blogs with different themes using one database where the content remains the same in both sites? The issue that I am getting is at the Domain mapping in both blogs.
0
votes
0answers
16 views

Return image urls with specific base string?

I have two wordpress sites on the same server (for ref call them site1 and site2). site2 hotlinks some images from site1. The problem is I recently used a CDN on site1 and told the CDN to disable ...
0
votes
2answers
801 views

Storing textbox values in Database

I am new to WordPress but I am good with PHP programmings, if I wanted to get value from the textbox and store it in the database in WordPress can I do? for ex form1.html <form name="form" ...
0
votes
0answers
16 views

dbDelta Not Working

I have some code with dbDelta that I'm trying to use to create a new database table for my plugin: <?php global $mm_importer_version; $mm_importer_version = '1.0'; function mm_install() { ...