Jump to:

23473 Posts in 18941 Topics by 2878 members

General Questions

SilverStripe Forums » General Questions » SOLVED - base url and home page link both have subfolder

General questions about getting started with SilverStripe that don't fit in any of the categories above.

Moderators: martimiz, Sean, biapar, Willr, Ingo, swaiba, simon_w

Page: 1
Go to End
Author Topic: 1742 Views
  • wainui
    Avatar
    Community Member
    56 Posts

    SOLVED - base url and home page link both have subfolder Link to this post

    Hi,

    I have a site installed using installer in a subfolder.
    The base url is

    <base href="http://localhost/silverstripe/"></base>

    But it seems that the subfolder is added onto the navigation urls as well?
    For example the home link referes to

    <a href="/silverstripe/">Home</a>

    I there any way to get rid of the subfolder in the nav links... I have tried changing the poath in the _config but doesnt seem to do anything.

    Mike

  • wainui
    Avatar
    Community Member
    56 Posts

    Re: SOLVED - base url and home page link both have subfolder Link to this post

    Fixed it using

    Director::setBaseURL('http://localhost/silverstripe/');

    In config

    1742 Views
Page: 1
Go to Top

Want to know more about the company that brought you SilverStripe? Then check out SilverStripe.com

Comments on this website? Please give feedback.