Title: Lyubomir Gardev's Replies | WordPress.org

---

# Lyubomir Gardev

  [  ](https://wordpress.org/support/users/rolice/)

 *   [Profile](https://wordpress.org/support/users/rolice/)
 *   [Topics Started](https://wordpress.org/support/users/rolice/topics/)
 *   [Replies Created](https://wordpress.org/support/users/rolice/replies/)
 *   [Reviews Written](https://wordpress.org/support/users/rolice/reviews/)
 *   [Topics Replied To](https://wordpress.org/support/users/rolice/replied-to/)
 *   [Engagements](https://wordpress.org/support/users/rolice/engagements/)
 *   [Favorites](https://wordpress.org/support/users/rolice/favorites/)

 Search replies:

## Forum Replies Created

Viewing 15 replies - 1 through 15 (of 28 total)

1 [2](https://wordpress.org/support/users/rolice/replies/page/2/?output_format=md)
[→](https://wordpress.org/support/users/rolice/replies/page/2/?output_format=md)

 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Post Sorter] Delete the plugin in myphpadmin](https://wordpress.org/support/topic/delete-the-plugin-in-myphpadmin/)
 *  Plugin Author [Lyubomir Gardev](https://wordpress.org/support/users/rolice/)
 * (@rolice)
 * [11 years, 1 month ago](https://wordpress.org/support/topic/delete-the-plugin-in-myphpadmin/#post-6314919)
 * Hello, if you want to manually remove the plugin data, make sure you first deactivate
   it. Mostly, post_sorter is writing in post_meta table with key defined in the
   main file:
 * `define( 'POST_SORTER_META_KEY', 'post_sorter_order' );`
 * So you can remove with phpMyAdmin all meta where key is `post_sorter_order`.
 * The plugin writes in options as well, where it stores the desired behavior selected
   in settings screen.
 * The keys of the options are:
    - post_sorter_custom_type
    - post_sorter_enabled
    - post_sorter_no_admin_sort
    - post_sorter_direction
    - post_sorter_enabled_roles
 * All the options and meta values are with prefix `post_sorter_`, followed by their
   ID, so you can search for such options.
 * However, I would not suggest removing this by hand, since WordPress stores its
   own plugin data (for active plugins) in own options (WordPress core-specific 
   ones), which may differ in different versions.
 * You can use Delete/Remove plugin after you deactivate it, this will clean you
   database.
 * Regards
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Post Sorter] Sorting Same Posts That Appear In Different Categories](https://wordpress.org/support/topic/sorting-same-posts-that-appear-in-different-categories/)
 *  Plugin Author [Lyubomir Gardev](https://wordpress.org/support/users/rolice/)
 * (@rolice)
 * [11 years, 9 months ago](https://wordpress.org/support/topic/sorting-same-posts-that-appear-in-different-categories/#post-5104241)
 * Work is still in progress. There is a lack of time these days in my schedule,
   but I will inform you as soon as I have status update.
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Post Sorter] Sorting Same Posts That Appear In Different Categories](https://wordpress.org/support/topic/sorting-same-posts-that-appear-in-different-categories/)
 *  Plugin Author [Lyubomir Gardev](https://wordpress.org/support/users/rolice/)
 * (@rolice)
 * [12 years ago](https://wordpress.org/support/topic/sorting-same-posts-that-appear-in-different-categories/#post-5104215)
 * This feature will require additional expansion of Post Sorter core. However, 
   such core update is planned in future, main releases. I will inform you when 
   the feature is going to be accessible.
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Post Sorter] Please add anon/off toggle to post list page in the backend](https://wordpress.org/support/topic/please-add-anonoff-toggle-to-post-list-page-in-the-backend/)
 *  Plugin Author [Lyubomir Gardev](https://wordpress.org/support/users/rolice/)
 * (@rolice)
 * [12 years ago](https://wordpress.org/support/topic/please-add-anonoff-toggle-to-post-list-page-in-the-backend/#post-4822182)
 * Feel free to check the new version 1.4.1. It should have a new option which disable
   sorting of admin lists.
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Post Sorter] Sorting Same Posts That Appear In Different Categories](https://wordpress.org/support/topic/sorting-same-posts-that-appear-in-different-categories/)
 *  Plugin Author [Lyubomir Gardev](https://wordpress.org/support/users/rolice/)
 * (@rolice)
 * [12 years ago](https://wordpress.org/support/topic/sorting-same-posts-that-appear-in-different-categories/#post-5104193)
 * Hello, let me inspect your question and research any possible directions that
   might help. Then I will write you back.
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Post Sorter] Please add anon/off toggle to post list page in the backend](https://wordpress.org/support/topic/please-add-anonoff-toggle-to-post-list-page-in-the-backend/)
 *  Plugin Author [Lyubomir Gardev](https://wordpress.org/support/users/rolice/)
 * (@rolice)
 * [12 years ago](https://wordpress.org/support/topic/please-add-anonoff-toggle-to-post-list-page-in-the-backend/#post-4822180)
 * Yep, confirmation is required to implement exactly what is needed. Thank you 
   for your reply. As soon as I get spare time I will release an update.
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Post Sorter] Please add anon/off toggle to post list page in the backend](https://wordpress.org/support/topic/please-add-anonoff-toggle-to-post-list-page-in-the-backend/)
 *  Plugin Author [Lyubomir Gardev](https://wordpress.org/support/users/rolice/)
 * (@rolice)
 * [12 years, 1 month ago](https://wordpress.org/support/topic/please-add-anonoff-toggle-to-post-list-page-in-the-backend/#post-4822173)
 * Hello, I have not received notification about this topic. As far as I understand
   you do not want the plugin to integrate itself with the post lists?
 * Additionally, you can turn it off by the “enable” check box.
 *   Forum: [Reviews](https://wordpress.org/support/forum/reviews/)
    In reply to:
   [[Post Sorter] It works](https://wordpress.org/support/topic/it-works-292/)
 *  Plugin Author [Lyubomir Gardev](https://wordpress.org/support/users/rolice/)
 * (@rolice)
 * [12 years, 8 months ago](https://wordpress.org/support/topic/it-works-292/#post-7806273)
 * Thank you for your assessment, I am glad it helped out.
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Post Sorter] How can i make it as only admin can edit but not all the user?](https://wordpress.org/support/topic/how-can-i-make-it-as-only-admin-can-edit-but-not-all-the-user/)
 *  Plugin Author [Lyubomir Gardev](https://wordpress.org/support/users/rolice/)
 * (@rolice)
 * [12 years, 9 months ago](https://wordpress.org/support/topic/how-can-i-make-it-as-only-admin-can-edit-but-not-all-the-user/#post-4313054)
 * [@duckmic](https://wordpress.org/support/users/duckmic/), please check the [development version](http://downloads.wordpress.org/plugin/post-sorter.zip)
   of the plugin and tell me if it works for you. In case it is working fine I will
   roll it out to public.
 * It contains permissions screen where you could select roles capable of operating
   with plugin functionality. These roles are read from WordPress, if there are 
   custom roles based on `WP_Role` everything should be fine.
 * Thank you.
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Post Sorter] How can i make it as only admin can edit but not all the user?](https://wordpress.org/support/topic/how-can-i-make-it-as-only-admin-can-edit-but-not-all-the-user/)
 *  Plugin Author [Lyubomir Gardev](https://wordpress.org/support/users/rolice/)
 * (@rolice)
 * [12 years, 9 months ago](https://wordpress.org/support/topic/how-can-i-make-it-as-only-admin-can-edit-but-not-all-the-user/#post-4312985)
 * Well currently, as I remember it checks, if the user can edit posts, for modification
   on the post edit page.
 * I can integrate such functionality, but it will require some time to do this,
   because it needs to be adaptive. It will contain a permissions settings screen
   for different roles and interface for enabling selected roles to use it.
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Post Sorter] Plugin makes custom Post types dissappear](https://wordpress.org/support/topic/plugin-makes-custom-post-types-dissappear/)
 *  Plugin Author [Lyubomir Gardev](https://wordpress.org/support/users/rolice/)
 * (@rolice)
 * [13 years, 1 month ago](https://wordpress.org/support/topic/plugin-makes-custom-post-types-dissappear/#post-3622243)
 * I have applied a fix for this issue, since no answer and my tests show working
   results I assume it is working. Marking the topic as resolved.
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Post Sorter] Automatic position based on popularity or custom field?](https://wordpress.org/support/topic/automatic-position-based-on-popularity-or-custom-field/)
 *  Plugin Author [Lyubomir Gardev](https://wordpress.org/support/users/rolice/)
 * (@rolice)
 * [13 years, 1 month ago](https://wordpress.org/support/topic/automatic-position-based-on-popularity-or-custom-field/#post-3345475)
 * I will continue work in this direction. Let me know if you have any questions
   up to then. You could open new support topic where we could discuss problems 
   targeted at this custom sorting.
 * Thanks, @3×7
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Post Sorter] arrow sorting buttons](https://wordpress.org/support/topic/arrow-sorting-buttons/)
 *  Plugin Author [Lyubomir Gardev](https://wordpress.org/support/users/rolice/)
 * (@rolice)
 * [13 years, 1 month ago](https://wordpress.org/support/topic/arrow-sorting-buttons/#post-3439473)
 * [@oakhillman](https://wordpress.org/support/users/oakhillman/), this latest version
   has an option for turning off arrows. Previous method of sorting had a bug it
   was sorting alphabetically, no matter if these positions were numbers.
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Post Sorter] Automatic position based on popularity or custom field?](https://wordpress.org/support/topic/automatic-position-based-on-popularity-or-custom-field/)
 *  Plugin Author [Lyubomir Gardev](https://wordpress.org/support/users/rolice/)
 * (@rolice)
 * [13 years, 1 month ago](https://wordpress.org/support/topic/automatic-position-based-on-popularity-or-custom-field/#post-3345473)
 * Hello, this escaping with backslash now should be fixed, please verify with the
   same code.
 * The problem with such custom fields is that the plugin does not know about them(
   any possiblity may vary) and does not know how to treat them (as integer number,
   decimal, money, text, etc., since in database they are all texts) that is why
   I have left this big text boxes.
 * I have an idea how to make it works for post metadata, but it will require a 
   new release with additional functionality, where you could have a lists of postmeta
   keys the user wants and the cast for each one which is required – how the plugin
   should treat them as number, monetary or alphabetically.
 * Actually it is possible to make such widget with these filters.
 * Example:
 *     ```
       add_filter( 'post_sorter_join', 'my_price_join' );
       add_filter( 'post_sorter_order', 'my_price_order' );
   
       function my_price_join( $sql ) {
          $join = "LEFT JOIN wp_postmeta AS post_sorter ON (wp_posts.ID = post_sorter.post_id AND post_sorter.meta_key = 'price')";
   
          return $join . $sql;
       }
   
       function my_order_join( $sql ) {
          $orderby = "CAST(post_sorter.meta_value AS DECIMAL(12,2)) ASC";
   
          return $orderby . ( $sql ? ', ' . $sql : '' );
       }
       ```
   
 * You could join them both (2 joins) with discount and order by both or some formula.
   You could take the sorting direction by external code and instead of ASC or DESC
   you can put that variable, for example, sorting direction retrieval from the 
   plugin:
 *     ```
       $direction = mb_strtoupper( get_option( 'post_sorter_direction' ) ) == 'DESC' ? ' DESC' : '';
       ...
       $orderby = "CAST(post_sorter.meta_value AS DECIMAL(12,2)) $direction";
       ```
   
 * Unfortunately, there is no front-end interface (widgets and so on) for controlling
   the sorting, but it could be implemented on this base.
 * Please check with **v1.3.1** and tell me if it is sorting by price correctly (
   with the previous two codes for join and order)?
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Post Sorter] Plugin makes custom Post types dissappear](https://wordpress.org/support/topic/plugin-makes-custom-post-types-dissappear/)
 *  Plugin Author [Lyubomir Gardev](https://wordpress.org/support/users/rolice/)
 * (@rolice)
 * [13 years, 1 month ago](https://wordpress.org/support/topic/plugin-makes-custom-post-types-dissappear/#post-3622241)
 * Please tell me if **v1.3** has resolved your issue?

Viewing 15 replies - 1 through 15 (of 28 total)

1 [2](https://wordpress.org/support/users/rolice/replies/page/2/?output_format=md)
[→](https://wordpress.org/support/users/rolice/replies/page/2/?output_format=md)