X-Cart: shopping cart software

X-Cart forums (https://forum.x-cart.com/index.php)
-   Changing design (https://forum.x-cart.com/forumdisplay.php?f=51)
-   -   Including a custom PHP? (https://forum.x-cart.com/showthread.php?t=12941)

inicom 03-21-2005 03:00 PM

Including a custom PHP?
 
Im trying to include a custom PHP file from the main.tpl, is that possible?

that file is a global php script that i use in my site where i define a bounch of variables and things that i would need to use to customize the xcart
is that such thing possible?

i have tryied using the smarty include but it gimme a lot of code errors when it parse the PHP, or something like that...

BTW, im using Version 4.0.12 under Linux & PHP4/Apache2

groovico 03-21-2005 03:07 PM

If the include with {PHP} {/PHP} doesnt work then you can always try using an iframe. Your only other alternative is to recode it or keep it external.

TelaFirma 03-21-2005 03:07 PM

This isn't exactly the best thing to do, but it is possible:

Code:

{php}
                // including a php script directly
                // from the template.
                include("/path/to/script.php");
{/php}



All times are GMT -8. The time now is 01:31 AM.

Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.