Skip to content
● Critical PHP security fixes are out: update PHP on your Grav sites. What to do →

Home_url with anchor at the end

Started by Matt 9 years ago · 2 replies · 1053 views
9 years ago

I'm using home_url variable to redirect users to my home page. But I want to redirect it to specific page. So, in normal html I can do something like this

mypage.com/#myanchor

How to do it with grav?
{{home_url}}/#anchor
dont work for me. Please, can anyone help me with that?

last edited 01/15/18 by Matt
9 years ago

Hi
What sort of link are you getting with home_url? I've got something like this using base_url working just fine on my policies page so I'd think the same idea would work on the homepage.

<a href="{{ base_url }}/policies#_cookie">Cookie Policy</a>

Suggested topics

Topic Participants Replies Views Activity
Support · by webmasterodp, 2 weeks ago
4 251 2 weeks ago
Support · by nwhitfield, 2 weeks ago
2 217 2 weeks ago
Support · by stell, 4 weeks ago
5 461 3 weeks ago
Support · by gravinator, 2 months ago
5 639 3 weeks ago
Support · by Gravver, 1 month ago
6 431 4 weeks ago