Log in

View Full Version : I need a a template program



marringi
03-27-2008, 04:06 PM
I'm looking for a template progam (preferebly cgi). I'm not talking about a normal header & footer script. What I need is for it to run numoures other scripts in it, based on what is written in the location of the script. If the loctation is "script.cgi?get=string". Then I want to be able to run scripts within the original script with "string" in it (script2.cgi?fromscript=string).

Don't know if I am making myself clear. Pretty hard to explain this.

Medyman
03-27-2008, 11:07 PM
Can you explain what you're planning to achieve with this approach? I have to admit that I didn't quite get what you really want but judging by the complexity and/or confusion in explaining it, I suspect that you might be taking an overly complicated approach.

If you can, explain what your end goals are and perhaps someone can chime in with some way of doing it. Otherwise, it might shed light on what it is that you're asking for (because again, I don't understand it...but someone else might).

marringi
03-28-2008, 12:33 AM
Hi and thanks for the repsponse.

The thing is...
I'm going to run different versions of a script with SSI, on many different places on a file.shtml. The best way to do this is would of course be with <!--#include virtual="/cgi-bin/example.cgi?argument1=value2&argument2=value2" -->. But I need to do it so many times and I only need to chane one argument in each "#include". That is basically the only difference beetween each layout: one word. It doesn't work to use javascript and "file.shtml?argument1=db1" and then use "db1" in the "<!--#include virtu.." because javascripts works after the page has loaded.

So in conclusion I am looking for a script where a string is written (script.cgi?arg=string) which would then be used in a sort of SSI way when including many types of databases/scripts within a shtml file of some sort.

It would be best if a template file would be made that the program would run. An then within the template a series of other scripts would be fetched and runned with the string that would be written at the end of the loctation. But I don't know if that is possible; that is, to run a script within another script, like SSI.

Hopefully someone understands me and can help me.

benslayton
03-30-2008, 05:52 AM
Just in case you would like to use php here ya go:
http://www.pixel2life.com/publish/tutorials/272/easy_php_navigation_using_the_id_pagename_feature/