codeasashu / hcz-jekyll-blog

A simple material theme for blogger
https://codeasashu.github.io/hcz-jekyll-blog
MIT License
247 stars 251 forks source link

Category listing does not make use of baseurl #5

Open GreatEmerald opened 8 years ago

GreatEmerald commented 8 years ago

In http://aboutashu.com/hcz-jekyll-blog/others/2016/06/04/example-content.html if you click on the "jekyll" breadcrumb, you get redirected to http://aboutashu.com/category/jekyll instead of http://aboutashu.com/hcz-jekyll-blog/category/jekyll.

Similarly, all links in http://aboutashu.com/hcz-jekyll-blog/category/jekyll don't make use of baseurl either.

codeasashu commented 8 years ago

Thanks for pointing this out. This is now fixed https://github.com/ashutosh2k12/hcz-jekyll-blog/commit/9d1ebbb40ed836088c5e2dbcaa7f58774df403fa

GreatEmerald commented 8 years ago

Not fully fixed yet: if you look at http://aboutashu.com/hcz-jekyll-blog/category/jekyll and press "others", it still doesn't use the baseurl.

codeasashu commented 8 years ago

Sorry, I overlooked. fixing again

codeasashu commented 8 years ago

Fixed in https://github.com/ashutosh2k12/hcz-jekyll-blog/commit/7c657ee244dbed3660c3596d01a2e860a9214888

GreatEmerald commented 8 years ago

There is still the issue with the actual links to the posts inside the category view, though.

GreatEmerald commented 8 years ago

Bump. Still an issue, see for example http://aboutashu.com/hcz-jekyll-blog/category/jekyll and click on "Welcome to Jekyll!".

GreatEmerald commented 8 years ago

To be specific, https://github.com/ashutosh2k12/hcz-jekyll-blog/blob/gh-pages/_layouts/posts_by_category.html#L44 needs a {{ site.url }} too.

brunojdo commented 8 years ago

Hi Guys, as a matter of fact, I still have a little problem with this URL redirect in categories. When I working in the project in localhost, the redirect is point to my dns brunojdo.github.io..., instead of 127.0.0.1:4000/....

So, to solve this I remove the / to the 44L of posts_by_category.html and this problem with URL redirect stopped!

Old: <h4 class="list-group-item-heading"><a href="{{ site.baseurl }}/{{ post.url }}">{{ post.title }}</a></h4>

<h4 class="list-group-item-heading"><a href="{{ site.baseurl }}{{ post.url }}">{{ post.title }}</a></h4>

I going to do a PR for this.