Jump to:

22983 Posts in 11709 Topics by 2827 members

General Questions

SilverStripe Forums » General Questions » Static publishing of pages with different URL that isn't accessible?

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: 373 Views
  • lanks
    Avatar
    Community Member
    61 Posts

    Static publishing of pages with different URL that isn't accessible? Link to this post

    I am trying to use the static publisher to statically publish my pages with a different URL.

    What I mean by this is that when I publish my pages in the CMS I am at www.mysite.com. But I want the pages to be rendered with all the URLs in the pages html to be the URL www.othersite.com.

    It seems to be that this can be done by using FileSystemPublisher::set_static_base_url('www.othersite.com').

    However when I use this the pages don't get rendered and cached with their content. All of the pages have the "Page Not Found" content. However all of the menu links in the pages are set to the URL 'www.othersite.com'.

    What I think is happening here is that the static publisher tries to request the page from www.othersite.com rather than www.mysite.com. But because the site currently isn't at www.othersite.com it returns a page not found.

    373 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.