How to do a 2-level php include() in User defined tag?

Help with getting the CMS CORE package up and running. This does not include 3rd party modules, PHP scripts, anything downloaded via module manager or from any external source.
Locked
Howbag

How to do a 2-level php include() in User defined tag?

Post by Howbag »

Hello!
I have a proxy php-script that works perfectly standalone. The thing with this script is that it includes another php-file.

Tag -includes- index.php -includes- index.inc.php

So when I include it via the user defined tag-thing in admin, I end up with lots of errors coming from the second php script that should be included aswell.

Anyone know of a way to get around this?
Slagar
Forum Members
Forum Members
Posts: 19
Joined: Sat May 10, 2008 11:42 am
Location: Auckland

Re: How to do a 2-level php include() in User defined tag?

Post by Slagar »

Hey Howbag, this may seem obvious, but would this work for you?

- Take the include out of your first external file
- Call your include UDT a second time, to include your second php file

So in your page you might have:
{ExtFile filename="file1.php"}
{ExtFile filename="file2.php"}

(Assuming 2-level PHP includes are not possible - I don't know, I haven't tried it:))
Locked

Return to “[locked] Installation, Setup and Upgrade”