[pLog-general] Including PHP

Oscar Renalias phunkphorce at gmail.com
Thu Dec 9 05:55:24 GMT 2004


Mike,

may I ask why you're trying to include php code in the templates? Is
it because of any specific functionality?

The whole idea of the template system is that php cannot be used
anywhere, making it theoretically more secure or at least making it a
bit more difficult for users of blogging sites to do that.

All said, you can still use the {php}...{/php} smarty tags as Brad
pointed out and include any php code you'd like to execute there:

http://smarty.php.net/manual/en/language.function.php.php

If you're planning to include(...) stuff, you might need to play with
the path or use the constant PLOG_CLASS_PATH to get a direct reference
to the folder where plog is installed.

Oscar


On Thu, 9 Dec 2004 11:52:37 +1300, Mike Welsh <yomcat at yomcat.geek.nz> wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
> 
> I was trying to include a file into the blueish template via PHP. Just
> editing the .template file outputted <?php include("this_file.php") ?>
> 
> How would I get around this and import the file?
> - --
> http://yomcat.geek.nz
> http://nztuatara.co.nz
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v1.2.4 (Darwin)
> 
> iD8DBQFBt4W18HRyQQw3+q0RAsZuAJ93sOGLJxti95TXVY1w5qwxw2CCbQCfdFXO
> e/03l8yAgiMjFB+shsGyS0s=
> =RzPs
> -----END PGP SIGNATURE-----
> 
> _______________________________________________
> pLog-general mailing list
> pLog-general at devel.plogworld.net
> http://devel.plogworld.net/mailman/listinfo/plog-general
>



More information about the pLog-general mailing list