WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] How do I set a page to a specific url? (3 posts)

  1. P1NBACK
    Member
    Posted 5 years ago #

    I believe I have the latest version of WordPress as I am new and just installed it.

    I have everything up and running. The first theme I tried was really basic, and worked ok. I set up a couple pages and no problems. At the top of my header, it made additional tabs for each of my pages and when I clicked on them, it sent me there.

    Now, I have just downloaded a more advanced theme. I believe it is set up with "permalinks" (if I understand permalinks correctly from what I read on this site) that give each link a specific url - for example, when I click on the "About" link at the top, it sends me to http://mywebsite.com/about

    The only problem with this is that I can't figure out how to link that with my "Pages" in the admin section.

    What I need help doing is setting my "Pages" to correspond with particular urls of my page. For example, I want my "About Us" page to correspond with the url I described above. For some reason, the theme isn't doing this for me automatically. Here is the code from the theme that I believe handles the "page links" at the top of the website (I put it in quotes):

    "<div id="wrapper">
    <div id="header">
    <div id="logo">
    /"><img src="<?php bloginfo('template_url'); ?>/images/logo-trans.png" alt="wpelogo"/>
    </div>
    <div id="pages">
    /about/"><span class="menu-items"><h3>About:</h3>Learn more about Everburning Press.</span>
    /contact/"><span class="menu-items"><h3>Contact:</h3>Questions or comments? Email us.</span>
    /product/"><span class="menu-items"><h3>Product:</h3>Get the latest supplements for your 4th Edition D&D game here!</span>
    /editorial/"><span class="last-menu-item"><h3>Editorial:</h3>Find our what we think.</span>
    </div>
    </div>"

    Any help on this would be fantastic.

    I've tried going into the "permalink" section and also looking for some way to set the urls of the pages manually and can't seem to find anything in the admin GUI.

  2. buddha trance
    Member
    Posted 5 years ago #

    It always helps to provide a link, so we can look at the site and the theme.

    It seems like these pages are created from pre-made templates.

    I can think of two possibilities.

    1 - If in your theme folder you find files such as about.php, editorial.php, etc., try to use that template for the page you have created, in Manage --> Pages --> Page Template drop down menu.

    2 - Since you have existing pages that you created prior to changing the theme, you can change the header call to the menu, so it will find your pages.

    Try this to change your "<div id="pages">"

    <div id="pages"><li class="<?php if ( is_home() or is_archive() or is_single() or is_paged() or is_search() or (function_exists('is_tag') and is_tag()) )
    	{ ?>current_page_item<?php } else { ?>page_item<?php } ?>"><a title="<?php bloginfo('name'); ?>" href="<?php bloginfo('url'); ?>">Home</a></li>
    
    	<?php wp_list_pages('depth=1&title_li=&exclude='); ?></div>

    It should work.

  3. P1NBACK
    Member
    Posted 5 years ago #

    Hey, this worked. Albeit with a different design, but this definitely gives me a great starting point! thank you!

Topic Closed

This topic has been closed to new replies.

About this Topic