Forums
This topic is locked
using templates
Posted 08 Jan 2002 14:52:28
1
has voted
08 Jan 2002 14:52:28 David Behan posted:
Here is a tough question I think!!!Everything is being done in asp and vbscript!
I want to use templates in ultradev but I dont want to use the dwt files to do it. The way I want to do it is different. I have seen it done and I know it works. Here goes...
I will be using a ready made website and customising it many times to suit each client I sell to. I want to be able to design any sort of a template page that I want using any layout that I think is suitable. On the template page I want a section to be called xxxPAGECONTENTxxx and have all the actual pages when loading, to delete xxxPAGECONTENTxxx and replace it with the actual page content such as listing of records, links to details, etc. Is this done using a "replace" script or what else do I need to do. I have been trying to work out how it is done from the script that I have from some where else but it is in so many different places that it is hard to understand. Any help would be very appreciative.
Cheeurs,
Dave
---------------------
David Behan - bmor.com
Replies
Replied 08 Jan 2002 17:23:22
08 Jan 2002 17:23:22 Viktor Farcic replied:
There's probably much better way but I don't have time right now to think about it. This will probably do the work.
First you need to read file and place it's content into variable (let's say 'strContent'). You can do this using FileSystemObject (www.aspfaqs.com/aspfaqs/ShowFAQ.asp?FAQID=24).
After content of some file is inside of variable replace 'xxxPAGECONTENTxxx' with whatever you need to be in that place. Something like:
<% Replace(strContent, "xxxPAGECONTENTxxx", "WhateverYouLikeToBeHere".
Using method similar to this you can allow clients to change the look of site by themselfs.
If you're just trying to make your work faster create site using CSS and SSI. Once you want to sell similar site to other client you'll just need to change SSI and CSS files (usualy two SSI -top and bottom- and one CSS -color, fonts, tables, background...-).
Edited by - vfarcic on 08 Jan 2002 17:32:19
First you need to read file and place it's content into variable (let's say 'strContent'). You can do this using FileSystemObject (www.aspfaqs.com/aspfaqs/ShowFAQ.asp?FAQID=24).
After content of some file is inside of variable replace 'xxxPAGECONTENTxxx' with whatever you need to be in that place. Something like:
<% Replace(strContent, "xxxPAGECONTENTxxx", "WhateverYouLikeToBeHere".
Using method similar to this you can allow clients to change the look of site by themselfs.
If you're just trying to make your work faster create site using CSS and SSI. Once you want to sell similar site to other client you'll just need to change SSI and CSS files (usualy two SSI -top and bottom- and one CSS -color, fonts, tables, background...-).
Edited by - vfarcic on 08 Jan 2002 17:32:19