[PATCH] Better handling of echo_ald_crp
-
You recently updated echo_ald_crp to add a $cache = 0 argument. This wasn’t the best move as ald_crp (which echo_ald_crp calls) accepts an array containing a variety of options. You’re limiting yourself unnecessarily. You should use the following instead:
function echo_ald_crp( $args ) { echo ald_crp( $args ); }
For reference what you currently have is:
function echo_ald_crp($cache = 0) { echo ald_crp('is_widget=0&cache='.$cache); }
is_widget already defaults to 0 in the ald_crp() method and cache defaults to 0 in crp_default_options().
Another benefit of this approach is that it will ALWAYS obey the user’s settings in admin. The version you have not only limits what you can do with echo_ald_crp, it actively ignores a users preferences.
https://www.ads-software.com/plugins/contextual-related-posts/
- The topic ‘[PATCH] Better handling of echo_ald_crp’ is closed to new replies.