Insert PHP in CMSB
8 posts by 3 authors in: Forums > CMS Builder
Last Post: August 12, 2008 (RSS)
By terryally - August 8, 2008
Is there a way to get this done please?
Terry
Re: [terryally] Insert PHP in CMSB
By Jake - August 10, 2008
If you use a plain text box field to enter in your PHP code it should work - I'm assuming you're trying to enter in this code through the WYSIWYG editor right now. Is that correct?
If you absolutely need to enter in this code through the WYSIWYG editor, I can see if there's a setting that can be adjusted to allow this in the WYSIWYG editor for you. [:)]
Cheers,
Jake Marvin - Product Specialist
support@interactivetools.com
Hire me!
Save time by getting our experts to help with your project. Template changes, advanced features, full integration, whatever you need. Whether you need one hour or fifty, get it done fast with Priority Consulting.
Re: [Jake] Insert PHP in CMSB
By terryally - August 11, 2008
I used the textbox instead of the wysiwyg and it reprinted the php on the page. Somehow the code was not processed server side.
Terry
Re: [terryally] Insert PHP in CMSB
By Jake - August 11, 2008
Sorry, that was my mistake - I was in an "Article Manager" way of thinking when I made that post.
The only way to actually execute extra PHP code like this would be to add it to your pages directly. Any PHP code entered into your database will not be processed, as the code needs to be parsed by the server before it comes from your database. This is something
Let us know if you have any other questions. [:)]
Cheers,
Jake Marvin - Product Specialist
support@interactivetools.com
Hire me!
Save time by getting our experts to help with your project. Template changes, advanced features, full integration, whatever you need. Whether you need one hour or fifty, get it done fast with Priority Consulting.
Re: [terryally] Insert PHP in CMSB
By Dave - August 11, 2008
Is there something in particular you're trying to do? There may be another way to do it that doesn't require inserting PHP code in your content.
interactivetools.com
Re: [Dave] Insert PHP in CMSB
By terryally - August 12, 2008
There is ways to execute PHP code but it's a little tricky and opens up a potential security hole. Also since PHP tags aren't valid html you have to get around the wysiwyg stripping them out.
Is there something in particular you're trying to do? There may be another way to do it that doesn't require inserting PHP code in your content.
Hi Dave,
I can find a work around for it. As I am structuring the site for the client to update I thought I would create a "footer" as a section and insert that on the template. As part of that footer I usually use PHP DATE() function to set the year and I thought it would be neat. What I've done is to hard code the PHP on the template and then still use the footer in CMSB with the other information. It still looks okay and fits with the design.
Cheers
Terry
Re: [terryally] Insert PHP in CMSB
By Dave - August 12, 2008
Hope that helps!
interactivetools.com