econnaissance

Forum Replies Created

Viewing 4 posts - 1 through 4 (of 4 total)
in reply to: Need to unlock my license #9370

Excellent. Thank you, Shaon!

Thank you very much for the quick-and-detailed reply, Shaon!

Your sample was very helpful! I only had to change two items to get it working: replace the double quotes in rel=’nofollow’ to single quotes (it was simply breaking everything due to the syntax error in this line); and replace $package[‘category’] with $vars[‘category’] (which is the proper variable name inside this function.

I also did another change to output a simple list of category names, without links, since in my case I only name to display the category names. Below is the final code I used, in case others find it useful:


function wpmp_package_cats($vars){
$categories = maybe_unserialize(get_option('_fm_categories'));
$cats = @maybe_unserialize($vars['category']);
$cats_output = '';

foreach($cats as $cat){
$cats_output .= ''.$categories[$cat][title].'';
}

if ($cats_output != '') {
$cats_output = ''.$cats_output.'';
}

$vars['the_categories'] = $cats_output;
return $vars;
}

add_filter('wdm_before_fetch_template',"wpmp_package_cats");

in reply to: Urgent unlock license key for Production Site #7340

Worked like a charm! Thank you so much, Shaon!

Cool. Any pointers to how could I do that myself?

Thank you,
Leo

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