get_settings('siteurl') Help! (relative links) (4 posts)

  1. cron
    Posted 10 years ago #

    I recently changed my blog from having all the files in the same place to having the blog homepage in a different directory than the wordpress files. (my index.php is in the exact same place but the rest of the files have been moved)

    I had wanted all my links to be relitave so if I switched servers they would not break. In order to do this I used the <?php echo get_settings('siteurl'); ?> function and put it in front of all my posts.

    However now that I have switched that peice of code displayes a link to the directory where the wordpress files are.* not to my blog homepage. What PHP code could I use to refrence the SQL table where my blog URL is ?

    If that is not posible how could I set up a hook to access it? Any help would be appreciated.


    *http://cron.quill.statichost.co.uk/wordpress/ as opposed to http://cron.quill.statichost.co.uk/.

  2. Kafkaesqui

    Posted 10 years ago #

    <?php echo get_settings('home'); ?>

  3. cron
    Posted 10 years ago #

    Thanks, I will try it out!

  4. cron
    Posted 10 years ago #

    Works great. How I love these forums....

    Thanks Kafkaesqui

Topic Closed

This topic has been closed to new replies.

About this Topic