Pods Template function callback
-
Hi,
so far I have had something like this in my custom Pods Template:{@ID,kka_get_pods}
…which worked just fine. “kka_get_pods” is the function in my theme’s “functions.php” and returns a chunk of HTML.
However, I had to move “kka_get_pods” function to the plugin due to the fact that certain things belong to plugin territory. Anyhow…
The question is: how do I call/access my function that is now part of the plugin?
I’ve tried:
{@ID,My_Plugin::kka_get_pods}
…but it doesn’t seem to work.
My function is public and declared inside the class. Somewhat standard thing.
class My_Plugin { private static $instance; public static function get_instance() { if( ! self::$instance ) { self::$instance = new self(); self::$instance->init(); } return self::$instance; } public function init() { // nothing to init yet } public function kka_get_pods() { // code } }
Viewing 5 replies - 1 through 5 (of 5 total)
Viewing 5 replies - 1 through 5 (of 5 total)
- The topic ‘Pods Template function callback’ is closed to new replies.