Wrox Programmer Forums
|
Classic ASP Basics For beginner programmers starting with "classic" ASP 3, pre-".NET." NOT for ASP.NET 1.0, 1.1, or 2.0
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Classic ASP Basics section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old January 30th, 2004, 01:55 PM
Authorized User
 
Join Date: Jan 2004
Posts: 13
Thanks: 0
Thanked 0 Times in 0 Posts
Default Creating htmls on the fly...

Say, you have about 50 htlms related to a site, and your site is consisted of 3-4 components: e.g. a menu on the left, a banner at the top, something at the bottom, and a center part that changes according to the selected menu... Do you have a code that combines top, left, bottom and the demanded center and makes one file on the fly...

Thanks...
 
Old January 30th, 2004, 02:03 PM
Friend of Wrox
 
Join Date: Jun 2003
Posts: 1,998
Thanks: 0
Thanked 3 Times in 3 Posts
Default

If you use ASP, you can use include files which contain the code for the menu, banner, and bottom parts of the code. You will have to rename the .html files to .asp, even if the content is static (.html doesn't support include files).
 
Old January 30th, 2004, 02:16 PM
Authorized User
 
Join Date: Jan 2004
Posts: 13
Thanks: 0
Thanked 0 Times in 0 Posts
Default

I gather that there is a command "include files" that adds the 'static' parts of my site and the dynamic one.

Thanks! Haven't even started ASP but having learned that this is possible, I'll start ASAP...
 
Old January 30th, 2004, 02:38 PM
Authorized User
 
Join Date: Dec 2003
Posts: 81
Thanks: 0
Thanked 0 Times in 0 Posts
Default

There is a command



These are ideal for your purposes...an added benefit,,change the code in the include file means it has been changed for every page calling it...a great time saver.

John

 
Old January 30th, 2004, 02:48 PM
Friend of Wrox
 
Join Date: Jun 2003
Posts: 1,998
Thanks: 0
Thanked 3 Times in 3 Posts
Default

You will want the top and left portions to be in a begin ASP page, such as:

and the bottom footer will be in an end ASP page in the same format as above. You can also specify:

Which starts from the virtual root of the application.

Brian
 
Old January 31st, 2004, 03:31 PM
Authorized User
 
Join Date: Jan 2004
Posts: 13
Thanks: 0
Thanked 0 Times in 0 Posts
Default

From John:

> an added benefit,,change the code in the include file means it has been changed for every page calling it...a great time saver.

Yes, that was actually why I was looking for the code. Many thanks to you all!





Similar Threads
Thread Thread Starter Forum Replies Last Post
Creating tables on the fly Keith Smith Access VBA 1 January 15th, 2008 10:49 AM
Creating a DTS package on the fly in C# dramz C# 0 July 18th, 2007 01:04 PM
creating textfield on the fly Acod Classic ASP Professional 1 April 25th, 2007 09:22 AM
creating controls on the fly mtrtxs Access 9 September 10th, 2004 04:51 AM
Creating form controls on the fly roniestein Access 6 December 23rd, 2003 01:30 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.