WordPress.org

Ready to get started?Download WordPress

Forums

Archives Page (5 posts)

  1. madskjaer
    Member
    Posted 6 years ago #

    I just set up an archives page and customized the template that came with wordpress. But linking to it by:

    http://www.example.net/?page_id=5

    is not very pretty, is it? Is there a way I can link to it by something similar to:

    http://www.example.net/archives ?

    With "normal" pages this is done by publishing them, but since I can't publish without breaking the page (it's a template) how can this be done? Do I have to manually write a rewrite expression in my .htaccess file or...?

  2. moshu
    Member
    Posted 6 years ago #

    You DO make a new Page using that template and you don't write anything in it. And then it will be published.
    You can never link directly to any template files!

  3. madskjaer
    Member
    Posted 6 years ago #

    That's exactly what I did. But then I have to link to it like:

    http://www.example.net/?page_id=5

    But I want the URL:

    http://www.example.net/archives

    Just like the "About"-page that "ships" with WordPress.

  4. moshu
    Member
    Posted 6 years ago #

  5. madskjaer
    Member
    Posted 6 years ago #

    If I try to create my own rewrite rules, I just get my wordpress 404 page.

    RewriteRule ^archives$ http://www.example.com/blog/?page_id=5

Topic Closed

This topic has been closed to new replies.

About this Topic