Muut Archive Legend
@Muut · Joined 9 years ago · 18337 posts · 3878 topics · 137 reputation
Badges
Recent posts
-
How do I install FaceBook Pixel to my grav site?
· 9 years ago
Like GA, Facebook pixel code needs to be added to every page on the site, so this is easiest achieved by adding the code to /yourtheme/templates/partials/base.html.twig.
-
How do I install FaceBook Pixel to my grav site?
· 9 years ago
Anyone that has integrated the facebook pixel into their grav site? How did you accomplish this? Is there a plugin for it like for Google Analytics?
-
Inline ordering
· 9 years ago
No problem @timomue! Glad you got it working in the end. A little tip is to use the dump(page) function to see what data is available, you can read more about it here: https://learn.getgrav.org/themes
-
Inline ordering
· 9 years ago
nevertheless, thanks for your advice, @robbinfellow !!
-
Inline ordering
· 9 years ago
changing the variable-name in the front-matter finally has helped. I chose: publish_date ... and it works.
-
Inline ordering
· 9 years ago
Try swapping 'date' with 'timestamp'. {% set posts = page.find('/blog/posts').children.order('timestamp', 'desc') %} ---
-
Inline ordering
· 9 years ago
simply swapping doesn't help
-
Inline ordering
· 9 years ago
thanks. but it seems that the first parameter is skipped during rendering process, only the default order is being kept. at least 'desc' seems to work. my frontmatter now looks like this: timestamp: '
-
Inline ordering
· 9 years ago
Try this: {% set posts = page.find('/blog/posts').children.order('date', 'desc') %} ---
-
Inline ordering
· 9 years ago
I want to order the output of: {% set posts = page.find('/blog/posts').children %} how can I order the children by header.date (a separate field in my page-frontmatter) descending ? thank you.