Save and load your snippet data with this plugin.
This plugin allows you to load snippet data into the page and treat them as part of the page.
This shortcode will load lot\assets\__snippet\txt\foo.txt
file into the page:
{{print:foo}}
This shortcode will load lot\assets\__snippet\txt\foo.txt
file into the page then will replace %1$s
with bar
and %2$s
with baz
:
{{print path="foo" lot="bar,baz"}}
This shortcode will load lot\assets\__snippet\php\foo.php
file into the page:
{{include:foo}}
This shortcode will load lot\assets\__snippet\php\foo.php
file into the page then will add a PHP variable named as $lot
with a value of array('bar', 'baz')
and $foo
with a value of 1
:
{{include path="lorem-ipsum" lot="bar,baz" foo="1"}}