Title: New Features Request
Last modified: April 3, 2018

---

# New Features Request

 *  [dufour_l](https://wordpress.org/support/users/dufour_l/)
 * (@dufour_l)
 * [8 years, 1 month ago](https://wordpress.org/support/topic/new-features-request-2/)
 * Hello dude
 * Thank a lot for this great plugin !
 * Here are some ideas of new features that I would find very interesting
 *  – Keep original date of post
    The idea would be to be able to use recycle post
   as usual, but without modifying the date of the post. For instance I use a photography
   blog and I post single photo as a post. I would like to be able to recycle a 
   post, but to keep the date of the post which in my case matches the day the picture
   was taken.
 *  – As we have a search keyword option, it would be nice if it could match a post
   title or if used with minus in front, remove post with a specific title from 
   being recycled. Exemple : -‘No Tiltle’ will prevent post with title ‘No Title’
   from being recycled.
 * Laurent Dufour
    [http://www.laurentdufour.net](http://www.laurentdufour.net)
    -  This topic was modified 8 years, 1 month ago by [dufour_l](https://wordpress.org/support/users/dufour_l/).
    -  This topic was modified 8 years, 1 month ago by [dufour_l](https://wordpress.org/support/users/dufour_l/).

Viewing 4 replies - 1 through 4 (of 4 total)

 *  Plugin Author [johnh10](https://wordpress.org/support/users/johnh10/)
 * (@johnh10)
 * [8 years, 1 month ago](https://wordpress.org/support/topic/new-features-request-2/#post-10143244)
 * 1) How would the post be recycled if the date stays the same?
 * 2) It should already do this and the keyword search is handled by the WordPress
   function [WP_Query](https://codex.wordpress.org/Class_Reference/WP_Query#Search_Parameter).
 *  Thread Starter [dufour_l](https://wordpress.org/support/users/dufour_l/)
 * (@dufour_l)
 * [8 years, 1 month ago](https://wordpress.org/support/topic/new-features-request-2/#post-10143325)
 * >> 1) How would the post be recycled if the date stays the same?
 * Well I assume the term ‘recycled’ in my case was not what I have in mind, I mean
   for instance if we use ‘auto post scheduler’ to recycle post in order to push
   post on instagram,facebook or tweeter or any social network (This is what I do),
   I do not need that ‘recycled’ post to appear ‘again’ on the front page of my 
   blog
 * >> 2) It should already do this and the keyword search is handled by the WordPress
   function WP_Query.
 * I tried already, and unfortunatly it does not exclude or include a title , nevertheless
   it works great whith tags.
 * But it seems that in WP_Query $args[‘s’] does not handle title, it would be $
   args[‘title’], but the behavior is not the same, it search in WP_Query for a 
   title, but I have not seen a way of excluding a title
    -  This reply was modified 8 years, 1 month ago by [dufour_l](https://wordpress.org/support/users/dufour_l/).
    -  This reply was modified 8 years, 1 month ago by [dufour_l](https://wordpress.org/support/users/dufour_l/).
 *  Plugin Author [johnh10](https://wordpress.org/support/users/johnh10/)
 * (@johnh10)
 * [8 years, 1 month ago](https://wordpress.org/support/topic/new-features-request-2/#post-10154049)
 * 1. To push posts to social networks you’ll have to look for a plugin that specializes
   in that. I don’t know of any that will only trigger ‘publish’ hooks, but I’ll
   add it to my todo list to look at in the future.
 * 2. I looked at WordPress class-wp-query.php and according to the code the search
   parameter should definitely search the post_title, post_excerpt and post_content.
 * `$search .= $wpdb->prepare( "{$searchand}(({$wpdb->posts}.post_title $like_op%
   s) $andor_op ({$wpdb->posts}.post_excerpt $like_op %s) $andor_op ({$wpdb->posts}.
   post_content $like_op %s))", $like, $like, $like );`
 * The ‘title’ parameter seems to do an exact match comparison.
 *  Thread Starter [dufour_l](https://wordpress.org/support/users/dufour_l/)
 * (@dufour_l)
 * [8 years, 1 month ago](https://wordpress.org/support/topic/new-features-request-2/#post-10154119)
 * Hello John
 * I did more search and here is what I have found
 * You are right the serach parametre works to find a title, but it does not work
   when it is used with a hyphen in front, so you cannot exclude title
 * Same things, with args[‘title’], it does not handle the hyphen in front, so no
   real solution with keyword search.
 * So I dig a little bit and found the solution here : [https://wordpress.stackexchange.com/questions/18703/wp-query-with-post-title-like-something](https://wordpress.stackexchange.com/questions/18703/wp-query-with-post-title-like-something)
 * It needs to use a filter
 * So I add one into the plugin
 * ///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
 * // Title Filter
    // // Source code ==> [https://wordpress.stackexchange.com/questions/18703/wp-query-with-post-title-like-something](https://wordpress.stackexchange.com/questions/18703/wp-query-with-post-title-like-something)//
 * function title_filter($where, &$wp_query){
    global $wpdb; if($search_term = $
   wp_query->get( ‘title_filter’ )){ $search_term = $wpdb->esc_like($search_term);//
   instead of esc_sql() $search_term = ‘ \’%’ . $search_term . ‘%\”; $title_filter_relation
   = (strtoupper($wp_query->get( ‘title_filter_relation’))==’OR’ ? ‘OR’ : ‘AND’);
   $title_filter_search_type = (strtoupper($wp_query->get( ‘title_filter_search_type’))
   ==’LIKE’ ? ‘LIKE’ : ‘NOT LIKE’); $where .= ‘ ‘.$title_filter_relation.’ ‘ . $
   wpdb->posts . ‘.post_title ‘.$title_filter_search_type.’ ‘.$search_term; } return
   $where; }
 * And to use it, in the function aps_auto_post
 *  if (!empty($aps_keyword_search)) {
    $args[‘s’] = $aps_keyword_search; //$args[‘
   exact’] = TRUE; }
 *  if (!empty($aps_title_search)) {
    //$args[‘title’] = $aps_title_search; add_filter(‘
   posts_where’,’title_filter’,10,2); $args[‘title_filter’] = $aps_title_search;
   $args[‘title_filter_relation’] = ‘AND’;
 *  if ($aps_title_search_negate==TRUE) {
    $args[‘title_filter_search_type’] = ‘
   NOT LIKE’; } else { $args[‘title_filter_search_type’] = ‘LIKE’; } }
 *  $args = apply_filters(‘aps_eligible_query’, $args);
 * So I modified the plugin “Auto Post Scheduler” to a new version to add a new 
   field for the title and a negate checkbox, and now it works, I have made a version
   1.80.1 that you can download here to see if you agree to use is or not
 * I also by the way add the option to keep the original date in this version, you
   can if you decide ton incoporate it , in your plugin rename the option to whatever
   your prefer in order to not confuse user
 * if ( $aps_recycle_keep_original_date ) {
 *  $update[‘post_date’] = get_the_date(‘Y-m-d H:i:s’);
    } else { $update[‘post_date_gmt’]
   = date(‘Y-m-d H:i:s’,current_time(“timestamp”,1)); $update[‘post_date’] = get_date_from_gmt(
   $update[‘post_date_gmt’]); }
 * Here is a link for download : [http://www.laurentdufour.eu/auto-post-scheduler-1.80.1.zip](http://www.laurentdufour.eu/auto-post-scheduler-1.80.1.zip)
 * To answer to your question, to post to social network, I already use another 
   plugin , it is called SNAP (Social Network Auto Poster), but to recycle I use
   your plugin, and the combination of both works like a charm.
 * Best Regards

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘New Features Request’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/auto-post-scheduler_bfcacf.svg)
 * [Auto Post Scheduler](https://wordpress.org/plugins/auto-post-scheduler/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/auto-post-scheduler/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/auto-post-scheduler/)
 * [Active Topics](https://wordpress.org/support/plugin/auto-post-scheduler/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/auto-post-scheduler/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/auto-post-scheduler/reviews/)

 * 4 replies
 * 2 participants
 * Last reply from: [dufour_l](https://wordpress.org/support/users/dufour_l/)
 * Last activity: [8 years, 1 month ago](https://wordpress.org/support/topic/new-features-request-2/#post-10154119)
 * Status: not a support question