Skip to content
Grav 2.0 is officially stable. Read the announcement →

Community guidelines

Please keep discussions civil and on-topic. Repeated violations may lead to a temporary ban.

Forms & Blueprints

Path for images is incorrect on child pages

Started by Nathan da Silva 6 years ago · 0 replies · 406 views
6 years ago

So I have a file called cliendland.yaml and I have a blueprint which shows up custom fields for all child pages of /clients/

The issue I am having is that the URL when I do the following:-

TWIG
{% for key, img in header.custom.ClientHero %}
    <div id="service-hero" class="page-hero" style="background-image: url({{ key }});">
{% endfor %}

The path for key is showing as:

/clients/user/pages/02.clients/04.main-contractors/contractor-hero-header.jpg

Whereas the file is actually storing it here:

/user/pages/02.clients/04.main-contractors/contractor-hero-header.jpg

You will see that the issue is that it is adding /clients/, either the file is storing in the wrong location or there is an issue with my blueprint file.

Any ideas?

last edited 05/07/20 by Nathan da Silva

Suggested topics

Topic Participants Replies Views Activity
Forms & Blueprints · by Ton Haarmans, 5 years ago
13 1165 4 months ago
Forms & Blueprints · by Hugo Oliveira, 5 months ago
0 89 5 months ago
Forms & Blueprints · by Flachy Joe, 6 months ago
9 163 6 months ago
Forms & Blueprints · by Augustus, 7 months ago
7 138 7 months ago
Forms & Blueprints · by Julien, 7 months ago
10 156 7 months ago