Can form entries from a WordPress form go to a database

WordPress supports Custom Post types, because this isn’t just about the form, but about displaying the data and making it searchable by other users – https://codex.wordpress.org/Post_Types I would recommend you look up http://pods.io/ which would help create these custom post types also build relationships between two post types (or Pods as they call it). Also … Read more

Split database on large site?

I had a similar issue on a website with ~100k rows in wp_posts and ~500k in wp_postmeta. Truth is WordPress have some really slow queries in the admin when you start to have a lot of posts. The best way to find the bottleneck is to use the Debug Bar plugin. You will probably find … Read more

Accessing external database: ERR_INCOMPLETE_CHUNKED_ENCODING

I found the solution by logging into the site FTP, renaming my WP site’s index.php to index.php_, and supplying this code in a new index.php file: <!DOCTYPE html> <html> <body> <?php $servername = “xxx.xxx.xxx.xxx”; $username = “xxxxx”; $password = “xxxxx”; try { $conn = new PDO(“mysql:host=$servername;dbname=xxxxxx”, $username, $password); // set the PDO error mode to … Read more

Need help for creating custom table on wordpress

I guess, you can use the following function public function pre_install() { global $wpdb; require_once(ABSPATH . ‘wp-admin/includes/upgrade.php’); $sql=” CREATE TABLE IF NOT EXISTS `”.$wpdb->prefix.”prelauncher` ( id mediumint(9) NOT NULL auto_increment, username tinytext NOT NULL, email varchar(255) NOT NULL, PRIMARY KEY (`main_id`) );”; dbDelta($sql); } and than your activation hook. register_activation_hook( __FILE__, array(‘main_class’,’pre_install’)); I dont think … Read more

How to filter get_adjacent_post()?

Well it wasn’t too hard after some perspective. public function get_adjacent_post_mod($where){ if (is_single()){ global $wpdb, $post; if ( get_post_status ( ) == ‘private’ ) { $where = str_replace( “AND ( p.post_status=”publish” OR p.post_status=”private” )”, “AND p.post_status=”private””, $where ); return $where; } else { $where = str_replace( “AND ( p.post_status=”publish” OR p.post_status=”private” )”, “AND p.post_status=”publish””, $where … Read more