New content files do not appear under taxonomy

Hi guys,

I have a problem and I can’t seem to fix it…

This is my code in my index.html:

  {{ with .Site.GetPage "taxonomies" "songs" }}
    {{ range first 50 ( where .Pages.ByWeight "Params.male" true ) }}
      <li><a href="{{ .Page.Permalink }}">{{ .Page.Title}}</a></li>
    {{ end }}
  {{ end }}

— songs
------- taylor-swift
------- bruno-mars

with this setup the code to get all the categories listed works great

But once i add songs (I want to do add them in the same folder as for each artist) the code doesn’t work anymore…

What can cause this? :frowning:


Do you assign the taxonomy songs in the front matter of the new content files?

What are the taxonomies settings in the project’s config?

P.S. I changed the topic title because it was not descriptive of the issue and also we do not use emoji in topic titles in this forum.

my taxonomies setting:

songs = "songs"

"songs" = "/songs/:slug/"

I already made it to work. I put .Site before .Pages.ByWeight… But still strange it didn’t work before…

It is a wild guess, but did you restart the Hugo server? I have run a few times into an inexplicable behavior after, say, moving a sub-directory, until I realized that it makes sense to restart the server first.

yes i did… thank you

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.