onweru / newsroom

A simple, minimalistic Hugo theme. View Demo here
https://rooms.netlify.app/
Other
287 stars 114 forks source link

In archieve page, next/previous page button's URL has an issue. [SOLVED] #18

Closed s-azizoglu closed 4 years ago

s-azizoglu commented 4 years ago

Hi @onweru ! I recently discovered your that theme and trying to migrate my site. I think it has great details. Really thank you!

When I try to click next or previous page in archive page (or page of posts), pager doesn't include the base URL that is domain name. I couldn't solve but working on it:

/layouts/partials/pager.html is our working file, if I'm not wrong.

In that file's this kind of line; <a href = '{{ $root }}{{ $paginator.Prev.URL }}' class = ' pager_item pager_prev'></a> $root has a issue. It should refer to .Site.BaseURL but it does not. You can also see from the screenshot. URL contains only post/page/2/ page-number

How could we solve this?

(I work on Windows 10 with R Studio, blogdown package. So, it may be caused or related with blogdown. If I can find a solution, I'll let you know. Because there was a same issue in your swift theme on the same working environment.)

s-azizoglu commented 4 years ago

Solution There should be a dot between {{ $root }} and {{ $paginator.Prev.URL }}