Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Reference some assets correctly #8

Open
wants to merge 3 commits into
base: develop
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions templates/partials/base.html.twig
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
<title>{% if header.title %}{{ header.title }} | {% endif %}{{ site.title }}</title>
{% include 'partials/metadata.html.twig' %}
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
<link rel="icon" type="image/png" href="{{ theme_url }}/images/favicon.png" />
<link rel="icon" type="image/png" href="{{ url('theme://images/favicon.png') }}" />

{% block stylesheets %}
{% do assets.addCss('theme://css/default.css') %}
Expand All @@ -19,14 +19,14 @@
{% do assets.addCss('theme://css/prettyPhoto.css') %}
{% endblock %}
{{ assets.css() }}
<script src="{{ theme_url }}/js/modernizr.js"></script>
{% do assets.addJs('/js/modernizr.js') %}
{% endblock head%}
</head>
<body>

<div id="preloader">
<div id="status">
<img src="{{ theme_url }}/images/preloader.gif" height="64" width="64" alt="">
<img src="{% url('theme://images/preloader.gif') }}" height="64" width="64" alt="">

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
<img src="{% url('theme://images/preloader.gif') }}" height="64" width="64" alt="">
<img src="{{ url('theme://images/preloader.gif') }}" height="64" width="64" alt="">

</div>
</div>

Expand Down
4 changes: 2 additions & 2 deletions templates/partials/footer.html.twig
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<div class="six columns info">
<div class="footer-logo">
<a href="{{ base_url_absolute }}">
<img src="{{ theme_url }}/images/footer-logo.png" alt="" />
<img src="{{ url('theme://images/footer-logo.png') }}" alt="" />
</a>
</div>
<p>
Expand Down Expand Up @@ -43,4 +43,4 @@
<a class="smoothscroll" title="Back to Top" href="#hero"><i class="icon-up-open"></i></a>
</div>
</div>
</footer>
</footer>
4 changes: 2 additions & 2 deletions templates/partials/header.html.twig
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
<header id="header">
<div class="logo">
<a {% if not page %}class="smoothscroll"{% endif %} href="{% if page %}{{ base_url_absolute }}/#hero{% else %}#hero{% endif %}"><img alt="" src="{{ theme_url }}/images/logo.png"></a>
<a {% if not page %}class="smoothscroll"{% endif %} href="{% if page %}{{ base_url_absolute }}/#hero{% else %}#hero{% endif %}"><img alt="" src="{{ url('theme://images/logo.png') }}"></a>
</div>

{% include 'partials/navigation.html.twig' %}
{% if site.social %}
{% include 'partials/social.html.twig' %}
{% endif %}
</header>
</header>