Question

i have a code in Wordpress 3.5.2 and works fine, but in 3.6 show like text (i have installed Exec-PHP too). maybe is because by $get_cats or similar? Important, i'm working on local with XAMPP.

<?php
$get_cats = wp_list_categories( 'echo=0&title_li=&depth=1&sort_column=name&show_count=0&hide_empty=0&show_option_all&child_of=0&exclude_tree=1&exclude=1,762,899,951' );
$cat_array = explode('</li>',$get_cats);
$results_total = count($cat_array);
$cats_per_list = ceil($results_total / 5);
$list_number = 1;
$result_number = 0;
?>

<ul id="category_footer_post" class="list-icon circle-no list-icon-color-dark list-icon-arrow" id="cat-col-<?php echo $list_number; ?>">

<?php
    foreach($cat_array as $category) {
    $result_number++;

    if($result_number % $cats_per_list == 0) {
    $list_number++;
    echo $category.'</li>
    </ul>

    <ul class="category_footer_post list-icon circle-no list-icon-color-dark list-icon-arrow" id="cat-col-'.$list_number.'">';

}

else {

    echo $category.'</li>';

    }

} ?>

</ul>
Was it helpful?

Solution

Ok, Exec-PHP don't work in Wordpress 3.6.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top