Muut Archive Legend
@Muut · Joined 9 years ago · 18337 posts · 3878 topics · 137 reputation
Badges
Recent posts
-
PHP Snippets
· 10 years ago
basically the phpcode show the onlinestatus of a gameserver. error_reporting(0); $fp = fsockopen("gameserver.com", 3000, $errno, $errstr, 1); if (!$fp) { echo '<div> gameserver.com
-
PHP Snippets
· 10 years ago
What is output exactly?
-
PHP Snippets
· 10 years ago
Hello all, i tried this code ---code <?php namespace Grav\Plugin; use Grav\Common\Grav; use Grav\Common\Plugin; class MyPlugin extends Plugin { public static function getSubscribedEvents() { return
-
PHP Snippets
· 10 years ago
The "grav-plugin-minicode" that takefumi posted is exactly the type of solution I was looking for. Unfortunately it does not seem to be processing php. I created a simple test.html file in the user/
-
PHP Snippets
· 10 years ago
You can look at that smartypants plugin i linked to above, or look through the plugin tutorial on the docs site.
-
PHP Snippets
· 10 years ago
Is this will be your help? https://github.com/gracix/grav-plugin-snippet
-
PHP Snippets
· 10 years ago
I really don't know anything about Twig. Can you please elaborate. How do I: "make sure you are subscribed to the onTwigExtensions() event,"
-
PHP Snippets
· 10 years ago
Another options is to create a simple plugin that adds a custom Twig extension. There is an example of this in the SmartyPants plugin. https://github.com/getgrav/grav-plugin-smartypants For example,
-
PHP Snippets
· 10 years ago
Cool, I need PHP functions too. Thanks for sharing!
-
PHP Snippets
· 10 years ago
I think the best way to run your custom PHP is to create a small plugin that adds a Twig variable where you can put the output of your PHP processing. Something along the lines of <?php namespace