alperenalpa adlı üyeden alıntı: mesajı görüntüle
$pages = $wp_query->max_num_pages;
12. satırı bu şekilde revize edin.
Notice: Trying to get property 'name' of non-object in /home/xxxxxxx/xxxxxxx.com/wp-content/themes/anka/widgets/tabbed.php on line 14


<?php if(!defined('ABSPATH')) exit; ?>
<div class="tabbedWidget safirWidget <?php echo "$widgetPlace"; ?>Widget">
    <div class="innerContainer">
        <div class="tabheading">
            <?php
            $tabbedCategories = array();
            for ($i=1; $i <= 8; $i++) {
                if(${"tabbedcategory" . $i}) $tabbedCategories[] = ${"tabbedcategory" . $i};
            }
            foreach($tabbedCategories as $tabbedCategory) {
                $category = get_term_by('id', $tabbedCategory, 'category');
                ?>
                <a class="color<?php echo $tabbedCategory ?>" href="<?php echo get_category_link( $tabbedCategory ) ?>">
                    <?php echo $category->name ?>
                </a>
                <?php
            }
            ?>
        </div><!--tabheading-->
        <div class="lines">
            <?php foreach($tabbedCategories as $tabbedCategory) : ?>
                <div class="line color<?php echo $tabbedCategory ?>"></div>
            <?php endforeach; ?>
        </div>
        <div class="tabs">
            <?php
            foreach($tabbedCategories as $cat) :
                if($cat != -1) :
                    ?>
                    <div class="tab advancedPostsWidget2 safirWidget color<?php echo $cat ?> <?php echo "$widgetPlace"; ?>Widget" style="padding:0"><?php
                        $queryargs['cat'] = $cat;
                        $results = new WP_Query($queryargs);
                        if( $results->have_posts() ) {
                            ?>
                            <div class="items">
                                <?php
                                while( $results->have_posts() )    {
                                    $results->the_post();
                                    include(get_template_directory() . "/posts/post2.php");
                                }
                                ?>
                            </div>
                            <?php
                            wp_reset_postdata();
                        }
                        ?>
                    </div><!--tab-->
                    <?php
                endif;
            endforeach;
            ?>
        </div><!--tabs-->
    </div><!--innerContainer-->
</div><!--tabbedWidget-->