Quantcast
Viewing all articles
Browse latest Browse all 19296

migswd on "[Plugin: W3 Total Cache] Dynamic content with mfunc"

Hello I made a shortcode function in functions.php to display 6 random authors among the whole list of authors. It works great without the cache. But when the cache is ON the list keep the same authors of course...

So I tried to understand about dynamic contect and fragmentation
AND I tried to use the famous MFUNC trick to keep my function dynamic but does not work.

See here in the bottom at the AUTEURS chapter
http://www.withoutmodel.com/

My shortcode in my homepage content :
[userslist nbusers="6"]

My function :
function MIGSWD_users_list ($atts, $content = null) {
?>
<!-- mfunc -->
<?php
.....
algorithm....
......
return $return_string;
?>
<!--/mfunc -->
<?php
}

function register_shortcodes(){
add_shortcode('userslist', 'MIGSWD_users_list');
}
add_action( 'init', 'register_shortcodes');

http://wordpress.org/extend/plugins/w3-total-cache/


Viewing all articles
Browse latest Browse all 19296

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>