Page 1 of 1

Using User Defined Tags

Posted: Tue Jun 16, 2009 12:08 pm
by obayesshelton
Say if I wanted to require a php file in the FAQ it tells me to

You can create a user defined tag (under Extensions >> User Defined Tags) and include the php code there. i.e: create a php tag called my_phpinfo and in it, place this code

  phpinfo();  //(notice that the tags aren't necessary).
Then you use the following syntax in your page to call that script:

  {my_phpinfo}


could some one show me the code in full with an example require src

please

Re: Using User Defined Tags

Posted: Tue Jun 16, 2009 12:27 pm
by NaN
I'm confused.
What about:

Code: Select all

require("your file here");
or

Code: Select all

include("your file here");
or

Code: Select all

require_once("your file here");
or

Code: Select all

include_once("your file here");
That's all.
In general you can just insert all kind of php code in an UDT and then calling this code with {UDT-NAME} in your template or content.