Wrox Programmer Forums
Go Back   Wrox Programmer Forums > Web Programming > Adobe Web Programming > Dreamweaver (all versions)
| Search | Today's Posts | Mark Forums Read
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Dreamweaver (all versions) 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 May 5th, 2004, 12:43 PM
Authorized User
 
Join Date: Nov 2003
Location: , , .
Posts: 85
Thanks: 0
Thanked 0 Times in 0 Posts
Default Batch convert .htm pages to .asp using template

I have a dreamweaver template which I have created from file-new-html page. It has the extension .dwt. But when I created it I had selected the basic-html page.
There are many .htm pages that depends on this template.
Now I need to turn all these pages into asp pages. I mean I need to make these pages to have the basic asp code that Dreamweaver adds to every new page and of course to be saved as .asp file.
Can I do it using my existing template?

If yes, how?
If no, What can I do to save my work and prevent creating them all from scratch.



 
Old May 5th, 2004, 02:01 PM
Authorized User
 
Join Date: Jul 2003
Location: New Milford, NJ, USA.
Posts: 26
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via AIM to chabrown Send a message via MSN to chabrown
Default

If you take a look at an ASP page, the only thing that is really different in the header is the language tag.

<%@LANGUAGE="JAVASCRIPT" CODEPAGE="1252"%>

You could have also used VB Script.

You could add that tag directly to the template. Just start a new asp page, and copy and paste that tag to the template.

Past that, all you need to do is to make give the newly created page the file extension of asp.

Let me know if that helps.

Charles E. Brown
Author - Beginning Dreamweaver MX, Fireworks MX - Zero to Hero
Contributor - Macromedia Studio MX Bible
 
Old May 5th, 2004, 02:42 PM
Authorized User
 
Join Date: Nov 2003
Location: , , .
Posts: 85
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Please explain me what do you mean.
I really try to understand but I cannot do it.

How can we make this specific .dwt file to be asp file? I take a look at the header of it's code and it has not any difference from a newly created asp page.
However, when I need to make a server side include -which is the reason I want to convert everything in asp-, I go to the menu 'Insert' and Dreamweaver does not display the 'Insert Application Object' choise. It displays other things that concerns the html-only pages.

So, how can keep this specific .dwt template, gain the capability to have all the asp's choises, and secondly, batch convert every file that depends on this template to a complete .asp file?


Thanks in advance


 
Old May 5th, 2004, 02:49 PM
Friend of Wrox
 
Join Date: Nov 2003
Location: , , .
Posts: 1,285
Thanks: 0
Thanked 2 Times in 2 Posts
Default

I think that once you save the file to .asp it adds the asp-based things to the menus.

Forgive me if I'm wrong, I don't use ASP much.

HTH,

Snib

<><
 
Old May 5th, 2004, 02:52 PM
Authorized User
 
Join Date: Jul 2003
Location: New Milford, NJ, USA.
Posts: 26
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via AIM to chabrown Send a message via MSN to chabrown
Default

I am assuming you created editable regions in the template. I am also assuming you are using ASP technology to create dynamic pages with a database. You need to put the Language declaration tag into the header of the template.

You then start a new page by selecting File > New > and in the dynamic category select ASP with whichever language you are using. Once the page is created, attach the template and save the new page with the asp file extension.

Then create the database connections, recordsets, etc. and drop them into the editable region with any text you need to put in.

Charles

Charles E. Brown
Author - Beginning Dreamweaver MX, Fireworks MX - Zero to Hero
Contributor - Macromedia Studio MX Bible
 
Old May 5th, 2004, 02:57 PM
Authorized User
 
Join Date: Jul 2003
Location: New Milford, NJ, USA.
Posts: 26
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via AIM to chabrown Send a message via MSN to chabrown
Default

Snib:

You are quite correct. From an actual operational standpoint, the only that really counts is that asp file extension. That tells the server who to hand it off too.

You would not save the template as an asp page; you would save the file you create with the template as the asp page. However, if the template is already created, you just need to add that language tag to the top of the code.

Charles

Charles E. Brown
Author - Beginning Dreamweaver MX, Fireworks MX - Zero to Hero
Contributor - Macromedia Studio MX Bible
 
Old May 5th, 2004, 03:54 PM
Authorized User
 
Join Date: Nov 2003
Location: , , .
Posts: 85
Thanks: 0
Thanked 0 Times in 0 Posts
Default

You said: "you just need to add that language tag to the top of the code."
But, it is already there. I even deleted this, and add it again, copied from a new blank asp page.
Once again Dreamweaver do not let me have asp function in this page, like inserting a server side include.

Can you please be more specific ?

Thanks in advance


 
Old May 5th, 2004, 04:04 PM
Friend of Wrox
 
Join Date: Nov 2003
Location: , , .
Posts: 1,285
Thanks: 0
Thanked 2 Times in 2 Posts
Default

karib:

Did you save the file with a .asp extension like we have been talking about?

HTH,

Snib

<><
 
Old May 5th, 2004, 04:14 PM
Authorized User
 
Join Date: Nov 2003
Location: , , .
Posts: 85
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Please Charles and Snib, forgive me if I misunderstood something.

So, which file to rename?
An instance of template?
But then this file will not be a template. Even more, it will not have my regions.
Even worst (i don't even think about) it will not be the main template to which all my pages are attached.

So, what can I do?


 
Old May 5th, 2004, 04:27 PM
Friend of Wrox
 
Join Date: Nov 2003
Location: , , .
Posts: 1,285
Thanks: 0
Thanked 2 Times in 2 Posts
Default

Excuse me for not elaborating. I did not mean rename, I meant Save As. About the template thing, why not just do this to create a new page: open the template, use Save As to create a new .asp file, then edit it.

Let me know if this is what you are looking for, or if I don't have your problem straight in my head.

Snib

<><




Similar Threads
Thread Thread Starter Forum Replies Last Post
Modifying Template-based pages ychange Dreamweaver (all versions) 1 March 22nd, 2007 01:55 AM
Convert a batch file to run in VBscript - WSH issu malcomm VBScript 0 October 25th, 2006 12:35 AM
convert asp pages to xhtml BrendonMelville HTML Code Clinic 1 March 14th, 2006 01:52 PM
convert asp pages to xhtml BrendonMelville XML 1 March 14th, 2006 11:34 AM
HTM pages with dynamic content madhukp Classic ASP Basics 3 June 10th, 2004 03:57 AM





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