Tag Info

New answers tagged

-3

SELECT ID, post_title, guid FROM posts WHERE post_type='product' and post_status='publish' and ID IN( SELECT object_id FROM term_relationships WHERE term_taxonomy_id ...


2

In typical use cases the performance cost of booting WordPress core for page load is significantly higher than querying for data. In other words it doesn't quite matter, because it won't be a bottleneck. You have to estimate: How close your data is to native WordPress concepts How much work (if any) it would be required to put it in such representation ...


0

I figured out my error in the query, Thank you all guys for responding, I just gave the piece of code <?php global $wpdb; $contactus_table = $wpdb->prefix."contactus"; //error with the query $sql = "INSERT INTO $contactus_table (firstname, lastname, email, query, reg_date) VALUES ('$firstName', '$lastName', '$email', '$query', ...


0

You have to do it yourself. It's just a frame of what it should be at least. Search more and use the format. The following is not checked, so it's your turn... :) <form action="" method="post" enctype="multipart/form-data"> <label for="first-name-text">First name: </label><input type="text" id="first-name-text" name="firstNametxt" ...


-1

function title_filter( $where, &$wp_query ) { global $wpdb; if ( $search_term = $wp_query->get( 'search_prod_title' ) ) { $where .= ' AND ' . $wpdb->posts . '.post_title LIKE \'%' . esc_sql( like_escape( $search_term ) ) . '%\''; } return $where; } function get_my_suggestions() { $search_term = $_GET['term']; $cat ...


0

The basic technique of logging queries is that if SAVEQUERIES constant is defined to be true (it's not by default for performance reasons) then $wpdb->queries will keep the log of queries performed. There isn't anything on top of this that WordPress natively does. There are plenty of plugins around which work either by interpreting this data, or ...


1

Well, WordPress.com it's the largest deployment of WordPress Multisite and they're basically using the same setup (multiple tables for each site), so you could say that it's a good strategy. This kind of setup would let you to, for instance, keep your VIP users on a dedicated box, or add multiple DB servers as the network grows. I've had experience with ...



Top 50 recent answers are included