Hi guys!
I’m trying to do a simple website with hugo, i used the hugo-base-theme as a start and I want that was my four links in my menu to have a anchor that link to the content in the page (like here http://gohugo.io/).
For now I just have one button who work with that line of code:
{{ if modBool $index 2 }}
{{ else }}
{{ end}}
but i don’t know why…
I find this code in an other topic:
[Foo]({{<ref “#foo” >}})
bla
bla
Hi!
Thanks for the answer!
I’m a big noob in dev so I don’t quite understand the use of relref
I have to put a line like this {{< relref “blog/post.md#who” >}}{{< relref “blog/post.md#who” >}} in my post and an id in a node page ?
aaah ok I’m getting it, I thought that the variable was sort of id… I put the relref function in my html and now when I click on the link it send to the adequate content but it only display the post without css or the rest of the site. The value that it send is /post/my_post/ am I missing something ?
Well, this is kind of hard to debug without seeing the complete project, but I have a problem seeing how the link should have anything to how the target looks. That sounds like a different problem.