Results 1 to 1 of 1

Thread: different pages to the single-ad_listing.php

  1. #1
    Thread Starter
    sitespronto's Avatar
    Join Date
    Jun 2014
    Location
    Curitiba-PR-Brasil
    Posts
    12
    Thanks
    0
    Thanked 0 Times in 0 Posts

    different pages to the single-ad_listing.php

    I use ClassiPress 3.3 and would like to use single-ad_listing pages with different visual for two types of categories, category-1: () vehicles (single-ad_veiculos 1.php tailor), category-2: (else if) Rent (single-ad_aluguel -2.php) and general category: the single-ad_listing who will get default. How to do this in ClassiPress 3.3? Has anyone used this way, what code should I use? I did this training put the code inside the single-ad_listing.php: and it did not work, where am I going wrong ?:
    <?php
    $post = $wp_query->post;
    /*if the rental category, show */
    if (in_category('alugue-por-dia')) {
    include (TEMPLATEPATH.'/single-ad_alugue.php');
    return;
    }
    /* if the vehicles category, show */
    if (in_category('veiculos')) {
    include (TEMPLATEPATH.'/single-ad_veiculos.php');
    return;
    }
    /* if not any of the categories above, shows */
    else { ?>
    <? include (TEMPLATEPATH.'/single-ad_alugue-por-dia.php'); ?>
    <?php } ?>

    . I appreciate the help.

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. single-ad_listing.php
    By bengt_helgesson in forum ClassiPress General Discussion
    Replies: 3
    Last Post: February 19th, 2014, 03:33 AM
  2. [SOLVED] How to translate (Email to a friend) to single-ad_listing.php
    By mart in forum Simply Responsive
    Replies: 2
    Last Post: September 9th, 2013, 01:19 AM
  3. While loop really needed on single-ad_listing?
    By einstein in forum ClassiPress General Discussion
    Replies: 1
    Last Post: February 10th, 2013, 03:30 PM
  4. [MOD NEEDED] Remove the Price when item is sold (from single-ad_listing; not loop-ad_listing) $
    By cgatherings in forum ClassiPress General Discussion
    Replies: 5
    Last Post: February 11th, 2012, 11:07 AM
  5. One more feature on single-ad_listing
    By casa in forum Report ClassiPress Bugs
    Replies: 1
    Last Post: September 9th, 2011, 08:19 AM