|
 |
|
| Author |
Topic: Can I use SSI pages for templates? |
|
John Foley

New Member
|
|
Hi I just purchased FM Sitesearch Pro - installation was a breeze, it works perfectly plus its very easy to integrate the output to match the look of my site - well done on producing such a great script!
My question is - is it possible to use a .shtml document as the main_layout.html template and if so how do I edit the script to enable this?
Thanks |
Total Posts: 1 | Joined:
Sep 1, 2002 - 1:23pm | IP
Logged
|
|
|
|
Sizzly

New Member
|
|
Another alternative would be to create a script with a name like "siteconfig.pl" and place a require call to it within all of your scripts that generate dynamic content.
The siteconfig.pl script should include subroutines that mimic the functions of your SSI calls. For example, if you have a script that generates random text on a page you'll want to put a subroutine in siteconfig.pl that runs the commands necessary to generate the random text and then put that text into a variable. Then put a call into your templates that requires a variable. The variable then calls the subroutine that will generate what used to be created via SSI.
I use this method for a number of my scripts and although it is sometimes difficult to ultimately configure so that each script can use the siteconfig.pl. The advantage to this method is that now your dynamic content is portable to just about all the scripts that you may want to use.
Rob
|
Total Posts: 8 | Joined:
Dec 12, 2002 - 3:41pm | IP
Logged
|
|
Nosmada

New Member
|
|
I have been struggling with this. Can someone give a detailed example please on how this would be done. Maybe sample coding for the call and sample coding for the master document?
|
Total Posts: 2 | Joined:
Nov 12, 2003 - 1:06pm | IP
Logged
|
|
|
Forum Legend |

|
New Member
|

|
Reply
to topic |

|
More
than 50 posts | Member
|

|
Reply
to topic with quoted message |

|
More
than 100 posts | Full Member
|

|
Edit
Message |

|
More
than 150 posts | Advanced Member
|

|
View
profile |

|
More
than 200 posts | Advanced Member |

|
Email
member |
|
|