• Resolved xercs

    (@xercs)


    I’m a wordpress newboy and have been struggling with Creating my own Page Templates. I have read the documentation below but it doesn’t mention how to then access the Template you have created.

    http://codex.wordpress.org/Pages#Creating_your_own_Page_Templates

    I have a template with :
    <?php
    /*
    Template Name: gallery
    */
    ?>

    But I now wish to call this via a URL link and can’t find any info. Please can someone help??

    Thanks,
    Paul

Viewing 9 replies - 1 through 9 (of 9 total)
  • You’ll need to apply that template to a page you create through the write page section. If you look in the right hand sidebar there will be a box for selecting which page template to use.

    Thread Starter xercs

    (@xercs)

    Thanks very much. How then can I link to such a page as a URL from my navigation menu ?

    just as you would any other page.

    say you choose the template “gallery” for your “about” page that comes on wordpress.

    when you go to the “about” page it will have the “gallery” template applied to it rather then page.php/index.php

    Thread Starter xercs

    (@xercs)

    Thanks but my questions is how do you link to the “about” page from somewhere else?

    should just be:

    <a href="[BlogURL]/about/"></a>

    am i missing something?

    Jeremy,

    I’m using version 2.3.3 and I can no longer find that select box. I found it in 2.1, and the site still works in 2.3.3, but I’m doing a second site, and I cannot find that item on the Write Page page.

    Thread Starter xercs

    (@xercs)

    FrankRichards, I am using 2.3.3 and I can see the write page option. Its actually a drop down option. I never used 2.1 so perhaps things have been moved around ?
    As for the link I think what I am after might be more along the lines of index.php?page_id=4
    The problem with this those is that comments are now also included on the page and I would like multiples posts accessible and not just the one.

    chazbeaners please can you clarify your recommendation, it seems to suggest that because I have a template called “about” a URL called “about” is now also accessible ?? Is this how wordpress works ??

    Cheers,
    Paul

    xercs,

    do some reading:
    re: “about” > Using_Permalinks
    re: Page templates in Write Page subpanel – it displays ONLY if you have a “named” Page template (not if you have only the default page.php)
    re: posts on Pages. That’s nonsense. Pages are Pages and posts are posts. Don’t mix them!

    Thread Starter xercs

    (@xercs)

    Thanks, what I actually needed was a category template. I wanted to display a different view based on which category the pilgrim was browsing. I should have articulated myself better.
    For anyone interested:

    http://codex.wordpress.org/Category_Templates

Viewing 9 replies - 1 through 9 (of 9 total)

The topic ‘Linking to a page template’ is closed to new replies.