Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Main page does not display post summaries #39

Closed
kode54 opened this issue Sep 21, 2018 · 7 comments
Closed

Main page does not display post summaries #39

kode54 opened this issue Sep 21, 2018 · 7 comments

Comments

@kode54
Copy link

kode54 commented Sep 21, 2018

I have configured my blog of posts exported from a WordPress site, with a configuration file almost identical to your site's.

When I use your theme with the example site, it generates a summaries page. When I use it with my own site, it generates a sidebar, but no summaries.

I can share access to a private Git repository of the site content, if necessary to diagnose.

@htr3n
Copy link
Owner

htr3n commented Sep 21, 2018

@kode54 : I'm not sure where exactly the problems are, I try my wild guess.

If the exampleSite is working fine whilst yours is not, then it is likely that there are some issues with your configuration or posts.

a) Please check again the folder name under content whether it is named posts because Hugo will derive the content type out of that.

The code where the posts are retrieved and listed is in layouts/index.html

{{ $paginator := .Paginate (where .Data.Pages "Type" "posts") }}
{{ range $paginator.Pages }}
...
{{ end }}

b) Please check the front matter of your posts to make sure there are no strange type parameter.

@kode54
Copy link
Author

kode54 commented Sep 21, 2018

The folder under content is posts, which contains all of the original blog posts, and there is nothing under my root layouts folder. Also, all of the posts have type: post, except for one, which I turned into a type: page, but that didn't stop it from appearing in the /posts/ index listing.

@htr3n
Copy link
Owner

htr3n commented Sep 21, 2018

index.html is under themes/hyde-hyde/layouts/ as we are talking about hyde-hyde.

@htr3n
Copy link
Owner

htr3n commented Sep 21, 2018

Can you remove the type: post on some of the posts and try again whether it works for these posts?

@kode54
Copy link
Author

kode54 commented Sep 21, 2018

Yeah, that fixes all of the posts I wanted displayed on the main index. Thanks.

@kode54 kode54 closed this as completed Sep 21, 2018
@htr3n
Copy link
Owner

htr3n commented Sep 21, 2018

@kode54 : Yeah, it's Hugo's convention and sometimes confusing though ;) Glad it works for your site.

@Anu-kriti
Copy link

I am also facing the similar issue.. I am unable to see the summary in my homepage. content/post folder is completely blank in my case. I generated html file of all rmd in content and pasted there still that didnt work.. the layout/index.html also seems fine with same as what I have in examplesite layout
plus the contact option I cant see in disqus, its saying some error in loading that
any idea what should i do here?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants