• Hi,

    I am developing a site in a subdirectory. When it goes live I will move it to the root directory.

    However, I need to link from lots of places to the “contact us” page.

    How can I put links in such that when I relocate the site they are still valid?

    Thanks.

Viewing 3 replies - 1 through 3 (of 3 total)
  • Something along this line should work:

    <a href="<?php bloginfo('url'); ?>/contact-us/">Contact Us</a>

    Will that work inside the post/page content without a run-php plugin?

    Will that work inside the post/page content without a run-php plugin?

    Not likely, and a good point to make. I would expect the code above to be used as “hard-code” in the custom template(s)/theme being created.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘How to add relative links within a site?’ is closed to new replies.