Skip to content

How do you link to a post (collection item)? #593

Answered by nathangross
nathangross asked this question in Q&A
Discussion options

You must be logged in to vote

Looks like it should be $post->getUrl(). I had tried that but it looks like if you don't have a layout set in your front matter (i.e. extends: _layouts.main), that will result in blank or null.

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@nathangross
Comment options

Answer selected by nathangross
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
1 participant