How much of my site can I recover from public_html?

All site content for your WordPress site is stored in the database. The files that query and display the data, store settings, etc, are in the theme and plugin folders. There is the wp-config.php file that stores access credentials for your database. And media files are stored in the wp-content folder, but media files locations … Read more

Get posts by multiple ID’s (query)

Did you look at the documentation for WP_Query? The p parameter takes only a single integer. Use post__in. $args = array( ‘post__in’ => array( 206, 189 ), ‘post_type’ => ‘product’, );

Only display posts after current date

Turns out meta_query was the way to go. This is the code I used to make it work. add_action( ‘pre_get_posts’, ‘filter_posts’ ); function filter_posts( $query ) { $now = date(“Y-m-d H:i”, strtotime(‘+2 hours’)); if( is_category() && !is_admin() && $query->is_main_query() ) { $query->set( ‘posts_per_page’,’10’ ); $query->set( ‘orderby’,’meta_value_num’ ); $query->set( ‘meta_key’,’date-start-custom’ ); $query->set( ‘meta_query’, array( array( ‘key’ … Read more

Post update RSS notification plugin

First this is clearly not a bug. Feeds generated by WordPress are ordered by post publication date, which is both intended and makes sense. Second RSS clients uniquely identify items. In specific case of WP feeds unique identifier is guid field with non-pretty (?p=xxx) permalink. Even if post is changed and brought back into feed … Read more

Adding Plugin-specific Fields with wp_insert_post()?

@sorich87’s answer is 99% there. The difference is that All-in-One SEO Pack follows certain best practices and uses a prefix of ‘_aioseop_’ on its meta keys. That makes the actual working code look more like this: $my_post = array( ‘post_title’ => ‘title’, ‘post_content’ => $post, ‘post_status’ => ‘publish’, ‘post_author’ => 1, ‘post_date’ => date(‘Y-m-d H:i:s’, … Read more

Disable author profile in post

There’s no exact “setting” in the backend/Admin UI. You’ll have to edit your template files (the php files that are in your theme folder). Search for something like <a href=””></a> where you got one (or more) of the php (wp native) function or variable: the_author_posts_link(); $curauth->user_url; get_the_author(); get_author_posts_url(); … or something theme specific Helpful is … Read more

Edit Post VS Custom Form

You are way on the safer and less effort involved side if having them access the admin interface is an option. In that case you could implement a custom post type for your needs, disable most of the ‘support’ flags when registering it, and add your own metabox to support latitude and longitude, as well. … Read more