Skip to content
● Meet Grav Guard: keep every Grav site you run secure and up to date, all from one place. Free for up to 3 sites. Read more →

Should we use `{{url("theme://"}}` or {{theme_url}}

Started by Muut Archive 10 years ago · 2 replies · 523 views
10 years ago

Hi, I was wondering is there a difference between:

<img src="{{ url("theme://" ~ 'statics/img/design/travel.jpg') }}" >

and

<img src="{{ theme_url }}/statics/img/design/travel.jpg" >

They both find the image path and both have exactly the same path, in absolute, from the server root.

Thank you,
Sebastien

10 years ago

theme_url is a shortcut to url("theme://"), so you can use both as you prefer.

Suggested topics

Topic Participants Replies Views Activity
Archive · by Muut Archive, 10 years ago
1 676 1 week ago
Archive · by Deleted User, 9 years ago
0 3043 9 years ago
Archive · by Muut Archive, 9 years ago
2 1983 9 years ago
Archive · by Muut Archive, 9 years ago
2 5338 9 years ago
Archive · by Muut Archive, 9 years ago
1 4135 9 years ago