Forum Moderators: open

Message Too Old, No Replies

Templating systems for large sites in .NET

or stick to classic ASP?

         

MrSpeed

12:58 pm on May 2, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



I am planning a 300 or so page web site and was wondering if there are any solutions that work well for architecting templates for a site built with .NET?

We have tried to use controls for the header and footer but it seems very cumbersome.

We would like to integrate personalization and .NET applications into the site so we want to build the entire site in .NET

We have two types of people that work on web sites. The C# developers and the webmasters that are used to tools like Dreamweaver and Homesite.

I'm kind of a firm believer that the "non-application" portion of the web site should be able to be edited in notepad. I don't want to compile just to modify some content or add new pages.

Thanks,

TheNige

8:26 pm on May 2, 2005 (gmt 0)

10+ Year Member



Do some searches on the ASP.Net forums for "Base Page Class"

I use this method and it works great. You esentially make a base page class that loads a header and footer user control. Then on any pages you create you simply inherit your new base page class instead of the default Page class.

mrMister

11:45 am on May 5, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



IMHO, if you're doing templates these daqys, it's best to use XSL in combination with XML.

If you do that, your code becomes platform independent. You can then use any programming language you wish.

Xoc

3:45 am on May 11, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



You might consider getting the beta of Visual Studio 2005 [lab.msdn.microsoft.com]. The next version of .NET has some superb page templating tools built into it. Microsoft is letting people use it for production use (with some stipulations [lab.msdn.microsoft.com]), even though it is still beta at this point.

f00sion

4:00 am on May 15, 2005 (gmt 0)

10+ Year Member



Including a bunch of user controls in every page is cumbersome. I have used implementations before where ever page inherits from a base page class but then you are stuck writing html output in your code, very hard to maintain. My favorite is to use master pages. ASP.Net 2.0 has native support for this but Paul Wilson has also created a very nice framework for it. Just do a google search for "paul wilson master pages" and you will be able to find plenty of info.

TheNige

9:29 pm on May 15, 2005 (gmt 0)

10+ Year Member



when using base page classes you do not need to "output HTML"...you simply create a class that loads the header and footer user control of your choice. You can write out the HTML with statements in the class if you want....but as mentioned not fun to maintain.