Results 1 to 4 of 4

Thread: Page buttons stucks

  1. #1
    Thread Starter
    Member smoke's Avatar
    Join Date
    Jan 2010
    Location
    Hong Kong
    Posts
    57
    Thanks
    2
    Thanked 0 Times in 0 Posts

    Page buttons stucks

    Hi,

    I have added 4 more categories in the front page next to "Just Listed" ,
    which were duplicated from block#1 (Just Listed).

    The problem is that the page button/ number buttons at the bottom are
    not working poperly with all 4 added categories. They are still linked back to the Just "Listed"category.

    This is what I did in index-standard.php.....

    Code:
    <li><a href="#block1"><span class="big"><?php _e('Just Listed','cp')?></span></a></li>
                   <li><a href="#block2"><span class="big"><?php _e('A','cp')?></span></a></li>
                  <li><a href="#block3"><span class="big"><?php _e('B','cp')?></span></a></li>
    <li><a href="#block4"><span class="big"><?php _e('C','cp')?></span></a></li>
    <li><a href="#block5"><span class="big"><?php _e('D','cp')?></span></a></li>
                </ul>
    
                <!-- tab 1 -->
                <div id="block1">
                  <div class="clr"></div>
                  <div class="undertab"><span class="big"><a href="#"><?php _e('Classified Ads','cp') ?></a> / <strong><span class="colour"><?php _e('Just Listed','cp') ?></span></strong></span></div>
    
                    <?php
                        // show all ads but make sure the sticky featured ads don't show up first
                        $paged = (get_query_var('paged')) ? get_query_var('paged') : 1;
                        $args = array('caller_get_posts' => 1, 'paged' => $paged,'category__not_in' => cp_get_blog_cat_ids_array(),);
                    ?>
    
                    <?php query_posts($args); ?>
    
                    <?php if (have_posts()) : ?>
    
                        <?php while (have_posts()) : the_post(); ?>
    
                        <?php // if(is_sticky()) continue; // don't show any sticky posts in the main section ?>
    
                            <?php // if (in_category(CP_BLOG_CAT_ID) || cp_post_in_desc_cat(CP_BLOG_CAT_ID) ) continue; // don't show any blog posts ?>
    
    
                          <div class="whiteblock can_chg_bg">
    
                                <a href="<?php the_permalink(); ?>"><?php if(get_post_meta($post->ID, 'images', true)) cp_single_image_legacy($post->ID, get_option('medium_size_w'), get_option('medium_size_h')); else cp_get_image($post->ID, 'medium', 1); ?></a>
    
                                <div class="priceblockbig">
    
                                    <h3><a href="<?php the_permalink(); ?>"><?php if (strlen(get_the_title()) >= 45) echo substr(get_the_title(), 0, 45).'...'; else the_title(); ?></a></h3>
    
                                    <p class="price"><?php if(get_post_meta($post->ID, 'price', true)) cp_get_price_legacy($post->ID); else cp_get_price($post->ID); ?></p>
    
                                    <div class="clr"></div>
    
                                    <p class="bot4px dotted"><?php _e('Category','cp') ?>: <?php the_category(', ') ?> | <?php _e('Listed','cp') ?>: <?php echo cp_ad_posted($post->post_date); ?></p>
                                    <p class="descr"><?php echo substr(strip_tags($post->post_content), 0, 200)."...";?></p>
    
                                    <div class="clr"></div>
    
                                </div>
    
                                <div class="clr"></div>
    
                          </div><!-- /whiteblock -->
    
                        <?php endwhile; ?>
    
                        <?php if(function_exists('cp_pagination')) { cp_pagination(); } ?>
    
                    <?php else: ?>
                        <div class="whiteblock can_chg_bg">
                            <h3><?php _e('Sorry, no listings were found.','cp')?></h3>
                        </div><!-- /whiteblock -->
    
                    <?php endif; ?>
    
    		<?php wp_reset_query(); ?>
    
                </div><!-- /block1 -->
    
    
    
    
                <!-- tab 2 -->
                <div id="block2">
                  <div class="clr"></div>
                  <div class="undertab"><span class="big"><a href="#"><?php _e('Classified Ads','cp') ?></a> / <strong><span class="colour"><?php _e('A','cp') ?></span></strong></span></div>
    
                    <?php
                        // show all random ads but make sure the sticky featured ads don't show up first
                        $paged = (get_query_var('paged')) ? get_query_var('paged') : 1;
                        $args = array('caller_get_posts' => 1, 'paged' => $paged, 'orderby' => rand,'category__not_in' => cp_get_blog_cat_ids_array(),'cat' => 9);
                    ?>
    
                    <?php query_posts($args); ?>
    
                    <?php if (have_posts()) : ?>
    
                        <?php while (have_posts()) : the_post(); ?>
    
                        <?php // if(is_sticky()) continue; // don't show any sticky posts in the main section?>
    
                        <?php // if (in_category(CP_BLOG_CAT_ID) || cp_post_in_desc_cat(CP_BLOG_CAT_ID) ) continue; // don't show any blog posts ?>
    
    
                          <div class="whiteblock can_chg_bg">
    
                                <a href="<?php the_permalink(); ?>"><?php if(get_post_meta($post->ID, 'images', true)) cp_single_image_legacy($post->ID, get_option('medium_size_w'), get_option('medium_size_h')); else cp_get_image($post->ID, 'medium', 1); ?></a>
    
                                <div class="priceblockbig">
    
                                    <h3><a href="<?php the_permalink(); ?>"><?php if (strlen(get_the_title()) >= 45) echo substr(get_the_title(), 0, 45).'...'; else the_title(); ?></a></h3>
    
                                    <p class="price"><?php if(get_post_meta($post->ID, 'price', true)) cp_get_price_legacy($post->ID); else cp_get_price($post->ID); ?></p>
    
                                    <div class="clr"></div>
    
                                    <p class="bot4px dotted"><?php _e('Category','cp') ?>: <?php the_category(', ') ?> | <?php _e('Listed','cp') ?>: <?php echo cp_ad_posted($post->post_date); ?></p>
                                    <p class="descr"><?php echo substr(strip_tags($post->post_content), 0, 200)."...";?></p>
    
                                    <div class="clr"></div>
    
                                </div>
    
                                <div class="clr"></div>
    
                          </div><!-- /whiteblock -->
    
                        <?php endwhile; ?>
    
                      <?php if(function_exists('cp_pagination')) { cp_pagination(); } ?>
    
                    <?php else: ?>
                        <div class="whiteblock can_chg_bg">
                            <h3><?php _e('Sorry, no listings were found.','cp')?></h3>
                        </div><!-- /whiteblock -->
    
                    <?php endif; ?>
    
            <?php wp_reset_query(); ?>
    
                </div><!-- /block2 -->
    As I don't know about coding, is there anything wrong with my code ?

    Thanks!

  2. #2
    jomarkosabel's Avatar
    Join Date
    Mar 2009
    Location
    Philippines
    Posts
    40,978
    Thanks
    170
    Thanked 3,407 Times in 3,278 Posts
    You must be an AppThemes customer and logged in to view this response. Join today!
    Please help our moderating team work more efficiently by not sending us support questions via PM. You can read more about how AppThemes support works here. However, you can send a PM to follow up and remind me if I missed your support request/thread.

    Thank you and have a nice day.

  3. #3
    Thread Starter
    Member smoke's Avatar
    Join Date
    Jan 2010
    Location
    Hong Kong
    Posts
    57
    Thanks
    2
    Thanked 0 Times in 0 Posts
    You must be an AppThemes customer and logged in to view this response. Join today!

  4. #4
    jomarkosabel's Avatar
    Join Date
    Mar 2009
    Location
    Philippines
    Posts
    40,978
    Thanks
    170
    Thanked 3,407 Times in 3,278 Posts
    You must be an AppThemes customer and logged in to view this response. Join today!
    Please help our moderating team work more efficiently by not sending us support questions via PM. You can read more about how AppThemes support works here. However, you can send a PM to follow up and remind me if I missed your support request/thread.

    Thank you and have a nice day.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [SOLVED] Job Type Buttons
    By diogobguerreiro in forum Help Using JobRoller
    Replies: 2
    Last Post: October 13th, 2010, 04:59 PM
  2. Orange Buttons
    By bidatio1 in forum ClassiPress General Discussion
    Replies: 3
    Last Post: June 25th, 2010, 01:17 PM
  3. Buttons
    By jayoungblood in forum ClassiPress General Discussion
    Replies: 1
    Last Post: February 3rd, 2010, 11:11 PM