Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

combine 2 asp pages into one

Status
Not open for further replies.

aarellano

MIS
Oct 22, 2007
168
US
Hello,

I have been trying to combine tow asp pages into one

Here is what I have done, it does not give me any errors, but it does not display any data.

Code:
<%@LANGUAGE="VBSCRIPT" CODEPAGE="1252"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "[URL unfurl="true"]http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">[/URL]
<html xmlns="[URL unfurl="true"]http://www.w3.org/1999/xhtml">[/URL]
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Untitled Document</title>
<style type="text/css">
<!--
#Layer1 {
	position:absolute;
	left:11px;
	top:10px;
	width:984px;
	height:202px;
	z-index:1;
}
-->
</style>
</head>

<body>
<%
<!--#include file="summary2.asp"-->
%>
<%
<!--#include file="summary1.asp"-->
%>
</body>
</html>
 
Code:
<%
<!--#include file="summary2.asp"-->
%>
<%
<!--#include file="summary1.asp"-->
%>

Get rid of the <% & %>

Code:
<!--#include file="summary2.asp"-->
<!--#include file="summary1.asp"-->

TIP: trying googling the answer before posting, you'll find that more times than not someone else somewhere has had the same request and posted an answer online.
----
I have recently been semi-converted to ensuring all my code (well most of it) works in both javascript and non-javascript enabled browsers
 
I tried that but it does not work
Error Type:
Active Server Pages, ASP 0141 (0x80004005)
The @ command can only be used once within the Active Server Page.
main.asp, line 1


I did a google look up but didnot find anything of this sort
 
I tried that but it does not work
Error Type:
Active Server Pages, ASP 0141 (0x80004005)
The @ command can only be used once within the Active Server Page.
main.asp, line 1

That is probabaly because your two include files also contain the line "<%@LANGUAGE="VBSCRIPT" CODEPAGE="1252"%>"

Remove that from the summary2.asp and summary1.asp and it should work.



TIP: trying googling the answer before posting, you'll find that more times than not someone else somewhere has had the same request and posted an answer online.
----
I have recently been semi-converted to ensuring all my code (well most of it) works in both javascript and non-javascript enabled browsers
 
^ sorry, I should add this:

If you need to keep the line at the top of each page and cannot remove it...use the following code:

<%
server.execute("summary1.asp")
server.execute("summary2.asp")
%>


TIP: trying googling the answer before posting, you'll find that more times than not someone else somewhere has had the same request and posted an answer online.
----
I have recently been semi-converted to ensuring all my code (well most of it) works in both javascript and non-javascript enabled browsers
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top