Closed jsilve24 closed 6 years ago
Have you clone enten/hugo-boilerplate to initialize your hugo's project?
How you named your base url variable in the config.toml
?
In modules/site/pagination.html#L1 we defines {{ $baseurl := .Site.BaseURL }}
.
So, I think there is a mistake with the name baseurl
in the config.toml
: the name may be baseURL
. I made that mistake in enten/hugo-boilerplate/config.toml#L2 too.
Here is the first few lines of my config.toml. I added both baseurl definition and BaseURL definition as I did not completely understand you last comment. I am still having the same issue...
# hostname (and path) to the root eg. http://spf13.com/
baseurl = "http://www.statsathome.com/"
BaseURL = "http://www.statsathome.com/"
using "baseURL" also does not fix the problem
Which version of hugo do you use?
I made a test a few minutes ago and I can't reproduce this issue. I'm using hugo v0.15.
$ hugo version
Hugo Static Site Generator v0.15 BuildDate: 2015-11-25T15:35:21+01:00
Hugo Static Site Generator v0.20.2 darwin/amd64 BuildDate: 2017-04-16T11:02:29-04:00
On Aug 10, 2017, at 2:46 PM, Steven Enten notifications@github.com wrote:
Which version of hugo do you use?
I made a test a few minutes ago and I can't reproduce this issue. I'm using hugo v0.15.
$ hugo version Hugo Static Site Generator v0.15 BuildDate: 2015-11-25T15:35:21+01:00 https://camo.githubusercontent.com/c6f40f56a416b13ad07c3cbe8f8c25952080e8bb/687474703a2f2f692e696d6775722e636f6d2f494c4d63354c502e706e67 — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/enten/hyde-y/issues/34#issuecomment-321639543, or mute the thread https://github.com/notifications/unsubscribe-auth/AAbnRslwrMuBXO05Tg7ixXcBJZwH3qDDks5sW0_3gaJpZM4OzoTb.
you can just download my site from
https://github.com/jsilve24/stats_at_home https://github.com/jsilve24/stats_at_home
and set paginate to 10, you should see the problem.
Justin
On Aug 10, 2017, at 2:46 PM, Steven Enten notifications@github.com wrote:
Which version of hugo do you use?
I made a test a few minutes ago and I can't reproduce this issue. I'm using hugo v0.15.
$ hugo version Hugo Static Site Generator v0.15 BuildDate: 2015-11-25T15:35:21+01:00 https://camo.githubusercontent.com/c6f40f56a416b13ad07c3cbe8f8c25952080e8bb/687474703a2f2f692e696d6775722e636f6d2f494c4d63354c502e706e67 — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/enten/hyde-y/issues/34#issuecomment-321639543, or mute the thread https://github.com/notifications/unsubscribe-auth/AAbnRslwrMuBXO05Tg7ixXcBJZwH3qDDks5sW0_3gaJpZM4OzoTb.
I still can't reproduce this issue with the v0.15.
I quickly check hugo's documentation and it seem there is not breaking change with .Site.BaseURL
.
I have been also discussing this issue no the Hugo forum. someone there seems to have figured out part of the issue with the theme.
https://discourse.gohugo.io/t/question-about-pagination-problem-with-hyde-y-theme/7919/4 https://discourse.gohugo.io/t/question-about-pagination-problem-with-hyde-y-theme/7919/4
On Aug 10, 2017, at 3:00 PM, Steven Enten notifications@github.com wrote:
I still can't reproduce this issue with the v0.15.
I quickly check hugo's documentation and it seem there is not breaking change with .Site.BaseURL.
https://camo.githubusercontent.com/17240b65736e6011d6bf03771479c58b7e3b04b8/687474703a2f2f692e696d6775722e636f6d2f6352506264324c2e706e67 — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/enten/hyde-y/issues/34#issuecomment-321643168, or mute the thread https://github.com/notifications/unsubscribe-auth/AAbnRpkR4WAsF8fijWwm1ZBWtjntPvyAks5sW1NGgaJpZM4OzoTb.
Wonderful!
I seen that pagination's section doesn't exists in the documentation until February 2017.
So this issue is due to the hugo's version.
Below a fix provided by @bep
Create a file in your local project
/layouts/partials/modules/site/pagination.html
With this content:
{{ template "_internal/pagination.html" . }}
Yes... but as I then followed up with. There is still a problem. Unfortunately, the pagination buttons are coming up as bullet points…
$ cd stats_at_home
$ cd themes/hyde-y
$ nano scss/_04-themes.less
$ # add the code below and save changes
$ npm install
$ npm run build:css
$ cd ../..
$ hugo server -w -D
/** stats_at_home/themes/hyde-y/scss/_04-themes.less */
.main_wrapper {
/** vvv Add lines below */
ul.pagination {
list-style-type: none;
}
ul.pagination > li {
display: inline;
}
/** ^^^ Add lines above */
&> .main_header {
/** ... */
}
}
Awesome!!! That totally fixed the problem! Thank you!
First off, thank you for creating this theme!
I am having a problem with Pagination. I now have 11 posts on my site: https://github.com/jsilve24/stats_at_home (http://statsathome.com) and I was introduced to the pagination feature which defaults to 10. This is great however clicking on the link to the second page leads to an invalid URL (http://page/2/). I am not sure how to fix this but help would be greatly appreciated!
I am not sure if there is other information I should be providing, it seems like it should be a simple fix...
Thank you, Justin