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.

Aaron Dalton Regular

@Perlkonig · Joined 8 years ago · 144 posts · 3 topics · 28 reputation

Badges

✏️ First Post 💬 Conversation Starter ❤️ Well Liked

Recent posts

  • Creating dynamic content with JS tools: any recommendations? · 8 years ago

    Félicitations! It feels good to get things working. Glad I could help a little.

  • Creating dynamic content with JS tools: any recommendations? · 8 years ago

    What exactly is being injected into the <script> tag when it appears at the top? If it's plugin://blah, then it's not going to work. You need to resolve it to a path reachable by the browser. I

  • Creating dynamic content with JS tools: any recommendations? · 8 years ago

    You need to resolve the locator syntax to an actual path. Try the following: $path = $this->grav['locator']->findResource('plugin://knockout/assets/[FILENAME]', false); $this->grav['asset

  • Creating dynamic content with JS tools: any recommendations? · 8 years ago

    I assume by "before" you mean "at the top of the HTML file"? That's fixable. See also the Google Analytics plugin for a live example.

  • Wordpress migration to Grav · 8 years ago

    The plugin, though out of date, can be made to work. It doesn't work out of the box anymore, though. But with a little tinkering a number of years ago, I got mostly useful output. I then spent a numbe

  • Cache-busting and assets · 8 years ago

    I apologize for sidetracking the conversation. I do not know of a native way to make Grav recognize these "virtual" files. If your method is deterministic, then you could maybe create a plugin that do

  • Cache-busting and assets · 8 years ago

    You only have to Ctrl+F5 because you're developing in real time. Assuming someone doesn't visit your site multiple times a day, this just shouldn't be a problem. A well behaving client will check the

  • Creating dynamic content with JS tools: any recommendations? · 8 years ago

    You would load it just as you would the general Knockout file (onAssetsInitialized), but you would reference it using the locator and checking the theme:// folder or wherever you ended up storing it.

  • Cache-busting and assets · 8 years ago

    I don't understand the problem. When you update the file, Grav should automatically invalidate the cache for that file. You shouldn't have to do anything weird. I certainly never have problems when I'

  • Creating dynamic content with JS tools: any recommendations? · 8 years ago

    You can load Knockout early in onAssetsInitialized (Datatables plugin). You can also add it later if you need to tweak it somehow (Tablesorter plugin). I don't know much about Knockout. Will every pos