Badges
Self employed developer and web witch. Building tiny shiny websites with Grav since 2018 (also some bigger ones). Tech is political!
Recent posts
-
$page->save() in plugin does not do anything, no errors either
· 7 years ago
Hello hughbris, and thank you for your reply! Yes, I did stumble over that little if clause as well, but wasn't sure what to do about it. I did not quite realise I could easily check for this by putti
-
$page->save() in plugin does not do anything, no errors either
· 7 years ago
In my Simple Events plugin, I would like to set the unpublish date of a new Event page programmatically. To this end, I am getting a list of all pages with the Event type on a cache rebuild, checking
-
How can I delete a page folder programmatically (in plugin)? thoughts on cron jobs welcome
· 7 years ago
Well hello again, thank you so much for this!! Not only would it not have occurred to me to use the cache rebuild, I could also copy most of your code as-is. Feels like I keep getting Christmas presen
-
How do I get all pages of a certain type in PHP (in a plugin)?
· 7 years ago
Hey there, that is a fair question! I wasn't fully aware of the unpublish_date especially. The thing is, these events can potentially have an end date… also I have set up an extra tab with only the re
-
How can I delete a page folder programmatically (in plugin)? thoughts on cron jobs welcome
· 7 years ago
Hello everybody, in my plugin Simple Events I would like to offer an option to have old events deleted automatically (for my own projects it would certainly be very useful). I have a problem with actu
-
How do I get all pages of a certain type in PHP (in a plugin)?
· 7 years ago
Hello there, thank you so much! This really helped me understand things better, and I quickly built a lovely two line solution: $pages = $this->grav['pages']; $collection = $pages->all()
-
How do I get all pages of a certain type in PHP (in a plugin)?
· 7 years ago
Hey everybody, I feel this should be simple, but I can't make it work. In my Simple Events plugin, I would like to add the option to automatically remove past events. To this intent, I need a collecti
-
Adding blueprints to plugin pages
· 7 years ago
Create a blueprint for your page, say gallery.yaml and put in the fields you want, or extend the default page (read the docs on that here). Put that blueprint in a blueprints/ folder in your plugin fo
-
Cannot save frontmatter fields with custom modal in Admin
· 7 years ago
Hello everybody, I have a custom page type (event) that I made a custom modal page creation form in Admin for, almost exactly as described in the docs. It works well so far, but I would like to add so
-
Plugin: do something onAdminSave, but only if folder isn't being moved
· 7 years ago
I still do not know the answer to this, but I actually found a better solution. So far I have been doing the custom processing bit in the event onAdminSave, and now I simply moved it under onAdminAfte