Template Generated Code

6 posts by 4 authors in: Forums > CMS Builder
Last Post: September 1, 2008   (RSS)

By dsc234 - August 31, 2008

Hello,

Is there a way that I can modify the generated code so that it automatically includes the header, footer, left navigation, and right navigation? In other words, I don't want to have to paste the generated code into my template, but rather have the template code included when CMS builder creates the 'ready to paste' code.

Any help is greatly appreciated.

Thanks,
Derek

Re: [Michael Blake] Template Generated Code

By Jake - August 31, 2008

Hi Derek,

As Mickey mentioned that type of templating system is present in our Article Manager product, but it's not possible to do with CMS Builder at this time. [:)]
-----------------------------------------------------------
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: [dsc234] Template Generated Code

By Dave - September 1, 2008

Hi Derek,

There's no easy or automatic way to do that. You could do it by modifying the code generator code.

Another way, that might be just about as easy, would be to have your header, footer, navigation, etc in include files and include them with single lines like this:

<?php include "/path/to/includes/header.html" ?>

Would that work for you?
Dave Edis - Senior Developer
interactivetools.com

Re: [Dave] Template Generated Code

By dsc234 - September 1, 2008

Hi Dave,

I already the files as server side includes and want it generated with the code. What file do I need to edit for the code generator?

Thanks,

Derek

Re: [dsc234] Template Generated Code

By Dave - September 1, 2008

Derek,

Assuming you have the latest version - it is:

/lib/menus/admin/showCode_functions.php

Make a backup first, then search for the functions:

_printHtmlHeader
_printInstructions
_printHtmlFooter

Hope that helps!
Dave Edis - Senior Developer
interactivetools.com