yulijia / freshman21

Welcome to use Jekyll theme Freshman21.
http://yulijia.net/freshman21/
MIT License
133 stars 90 forks source link

Change `site.url` to `site.baseurl` can make it work at localhost #3

Closed imrickysu closed 9 years ago

imrickysu commented 9 years ago

Ap categories.md and tags.md, creating post links with {{site.url}} always direct the link to external website. In the situation that user would like to preview posts at localhost, change {{site.url}} to {{site.baseurl}} helps to make the theme work at both localhost and remote server.

yulijia commented 9 years ago

Thanks a lot. I fix all site url bugs, now user can preview site at localhost with correct links.

yulijia commented 9 years ago

a great article about site.url and site.baseurl.

TL;DR: Use baseurl when you are building a site that doesn’t sit at the root of the domain.