Skip to content

Instantly share code, notes, and snippets.

@bobdenotter
Last active August 29, 2015 14:25
Show Gist options
  • Save bobdenotter/258f97079c0026654c81 to your computer and use it in GitHub Desktop.
Save bobdenotter/258f97079c0026654c81 to your computer and use it in GitHub Desktop.
hackishly using SQL in Twig templates in Bolt
{% set stmt = app.db.query("SELECT id FROM bolt_pages;") %}
{% for row in stmt.fetchAll() %}
{% setcontent page = "pages" where {'id': row.id } %}
{{ dump(page) }}
<hr>
{% endfor %}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment