Page 1 of 1

Updating to get PHP support

Posted: Wed 12. Dec 2012, 22:19
by B1234
Hello!

I just became a webmaster for a phpwcms website and I'm new to phpwcms.
It is currently running on version 1.3.3

The other day I wanted to add a piece of PHP code to an article.
I was searching for a proper shorttag to include an external php file.
Does anyone know what the proper shorttag is? Mine didn't work.

I thought about updating the phpwcms because maybe php inclusion isn't supported in my low version, is this true?

Thanks in advance! :D
Bas

Re: Updating to get PHP support

Posted: Thu 13. Dec 2012, 08:26
by flip-flop
Hi,

please have a look:

{PHP:my_external_PHP_script.php} -> http://www.phpwcms-docu.de/system_tags.phtml

[PHP]echo FE_CURRENT_URL[/PHP] -> http://www.phpwcms-docu.de/system_tags.phtml (not recommended)

Content Part "Ext. Content" -> http://www.phpwcms-docu.de/content_part ... tent.phtml

/frontend_render/ script -> http://www.phpwcms-howto.de/wiki/doku.p ... end_render (recommended)

Knut

Re: Updating to get PHP support

Posted: Thu 13. Dec 2012, 11:19
by B1234
Thank you for the response!

The external content type worked :)
The other php shorttags did not. Which must I make the article for the others to work?

Regards,
Bas

Re: Updating to get PHP support

Posted: Thu 13. Dec 2012, 13:11
by flip-flop
Frontend render Script:

Script in folder: template/inc_script/frontend_render/

Requirement: $phpwcms['allow_ext_render'] = 1; (In the file config/phpwcms/conf.inc.php)


PHP replacement tag e.g.: [PHP]echo FE_CURRENT_URL[/PHP]

Requirement: $phpwcms['allow_cntPHP_rt'] = 1; (In the file config/phpwcms/conf.inc.php)

Knut