• Is it possible to have two templates? I need to have on index listing as a single column and then a multi cloumn listing which I have working on the homepage of the site in question. I know I can use the shortcode in the sidebar and would like to post the same information in the sidebar. and the widget just references the index page. So if I could get a second template to work I could get what I’m looking for completed.

    Thank you in advance for any help you can give me.

    The page I need help with: [log in to see the link]

Viewing 1 replies (of 1 total)
  • Plugin Author Dani Llewellyn

    (@diddledani)

    This isn’t possible when you’re including both listings on the same page. If you have two separate pages then this is possible in a very limited way based on the top-level page in the hierarchy (it only works on posts of the type page).

    I’m assuming this won’t help you because it’s such a limited feature currently, but I’ve included the details of how it works for completeness:

    Currently the code will look at the top-level page in the hierarchy chain to determine the section of the listing, and will look for a specific template in your theme called a-z-listing-$section.php where $section is the slug of the top-level page.

    For example if I have pages like:

    home
    blog
    - a-z-listing
    about

    Then the a-z-listing at blog/a-z-listing will use blog as it’s “section” name. This requires that both blog and a-z-listing are page post-type, and the a-z-listing page has blog set as it’s parent.

    I want to improve this so that it is easier to use different templates, because the “section” method is very restrictive and was built as a dirty hack for a specific client site with the intention to “fix it later”.

Viewing 1 replies (of 1 total)
  • The topic ‘More then one Template’ is closed to new replies.