Include From Different Server
I am trying to Include a file in my ASP page, but not a file that is on my server, but on another server, this executes a error message, is ther anyway to do this?The Error msg:
Active Server Pages, ASP 0126 (0x80004005)
The include file 'Http:...x.asp' was not found
View Replies
ADVERTISEMENT
If I have multiple websites on the same server,can I use the #include directive to reference include files elsewhere on the server? I tried this -
<!--#include file="C:InetpubvhostsATRAMEMBER.COMhttpdocsheader.asp" -->
But no dice...
View Replies
View Related
I am trying this in a site
<!--#include file="http://www.othersite.com/page.asp" -->
and it keeps coming back that it can't do the same?
View Replies
View Related
I have page which uses two server includes. The first displays a random banner advert. The second displays a form containing dropdown boxes populated from a database.
The includes work seperately but when I include them together I am getting an error. The includes share the same database but use different tables.
Does anyone have any ideas as to what could be causing the conflict between the two includes?
Here is my code for the BANNER .....
View Replies
View Related
I've got an include file inside each page throughout my site. Inside this
include file I'm running server.execute to include other pages based on a
condition (userID).
The problem has two parts-
1) The CPU usage jumps up to 100%
2) The path for these include files is different according to the file that
is calling server.execute, resulting in an invalid path
I'm not sure the best way to go about this. Basically all I'm trying to do
is run server.execute from within an include file, regardless of where the
calling page is inside my site structure.
This will be running off of an IIS 5 box and is being tested with IIS 6.
View Replies
View Related
I'm looking for a way to include a file from another server in asp page.using #include won't work because it's not on the same server. In php, you can simply include(), and it doesn't care whether or not it's on the same server, is there a similar function in asp?
View Replies
View Related
When using a Server side include in IIS 6.0 in an .asp page to include connection information I get the following error: Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified. The pages work fine on IIS 5 but give me this error even though I can test the ODBC Connection and it works fine.
View Replies
View Related
which one is better? why? if I use server.execute, I can run dynamic queries
like server.execute("A.asp?id="&request("id"))
But I cant do it if I use include method? what do you think about this ?
View Replies
View Related
Don't have any experience with ASP but am trying to cobble together a page that randomly loads one of three server side includes. My code so far is below but of course it doesn't work. Any pointers?
<%
RANDOMIZE
Response.write("<!--#include file='includes/home" & INT((3)*RND()) & ".txt' -->")
%>
View Replies
View Related
i have recently completed and tested a site in using IIS on my desktop as a server,
and everything runs fine. Upon transferring all the files up to the Real Server at work,
the ASP pages are not displayed as i get an error saying that the include files caanot be found.
The include files for my ASP pages are in a folder called 'includes' which sits in the same dir as the ASP files. This setup works fine on IIS on my desktop, but for some reason, this same setup is not working when the files are on the Server. Has anyone got any ideas as to why this might be happening?
View Replies
View Related
I have 9 asp-sites on a Win2003 server, and would like to use the same
include file, but it does not work.
The path for the servers default website (which is not where the
problem is) is c:inetpubwwwroot and the rest of the sites are at
c:inetpubwwwrootwebsitesSite1 , ..Site2 etc.
I tried using the following on the secondary sites:
<!--#include virtual="Websites/Include.asp" -->
<!--#include virtual="/Websites/Include.asp" -->
<!--#include file="../Include.asp" -->
All works fine on my development machine (Win2k) and on the server
(Win2003) when it is accessed through the LAN, but when I cut the LAN
and access the server through www (e.g. http://www.site1.dk) it does
not work.
I suspect that the internet user does not have rights to the virtual
path, but how do I solve that?
View Replies
View Related
I need to pass a static parameter to an included ASP file. I'm thinking about using this with a query string, but upon reflection I'm not sure how I can do this. For example:
---file start: FIRST.ASP ------
<%
Server.Execute("second.asp?a=1")
%>
<!--- ***** or ***** --->
<!-- #include file="second.asp?a=2" -->
-----file end: FIRST.ASP --------------
Now, if I do a Request.QueryString("a") in second.asp, is it performing a query on FIRST.ASP then? How can I retrieve the parameter?
View Replies
View Related
Can I separate the code inside of script into SSI files so that I have reusable code? Is it even possible?
<%
' code
<!--#include file="email_footer.inc" -->
' more code
%>
email_footer.inc has this content in it:
strHTML = strHTML & "Questions about this application?<P>Please contact the helpdesk:
View Replies
View Related
I am working on a App. at my work place, now wanting to set it up at home
but for some reason I keep getting this error :
ADODB.Command (0x800A0BB9)
Arguments are of the wrong type, are out of acceptable
range, or are in conflict with one another.
I did some research on the NET but I am still unable to figure out why I
cannot connect to my db. Code:
View Replies
View Related
I've got an application that I want to redirect to another file while keeping the location of the file hidden. In other words,
WEBROOT.COM/REDIT.ASP?a=14
is going to display the contents of file
WEBROOT.COM/SECURE12954
without the user knowing they are in the /SECURE12954 subdir.
Which is better to protect that privacy the name of the /SECURE12954 subdir?
<%Server.Transfer("/SECURE12954")%>
or
<%Response.Redirect("/SECURE12954")%>
or
<!-- #include file="/SECURE12954" -->
View Replies
View Related
I have a provider to implement domain name search and another to receive variables from my site and save them on thier site.
PROBLEM
we are using MS ASP scripts on my site.
We want to be able to implement an include file to show the results of the form process from their website.
Currenlty i tried the ASP script below but it fails, complaining of the end if statement, when i remove it, it doesnt show anything. Code:
View Replies
View Related
I've been browsing this and a few other related newsgroups trying to get my head around this problem, and so far all the trails seem to go cold, without an acceptable solution being reached. I'm posting here because there seems to be a few MVP's knocking around, and if they dont know, then it's a safe bet nobody does.
I'm beginning to think that what I want to do is simply not possible - but i'll put it out there once more.
Here goes: I'm writing a content managaement system - and i'm making use of dynamic includes via the "read a text file" technique, and then substitiuting values into markers in the template. Code:
View Replies
View Related
I'm getting this erro.wht does it mean
Code:
Active Server Pages error 'ASP 0234'
Invalid include directive
E:INETPUBESVC001320HTML../assets/lib/MSDBConnection.inc, line 2
Server side include directives may not be present in script blocks.Please use the SRC= attribute of the <SCRIPT> tag.
View Replies
View Related
There seem to be two ways to include files on the server:
1. <!-- #include file="header.inc" -->
2. <script language="VBScript" runat="server" src="header.inc"></script>
What are the differences between the two, and when to use one instead of the other?
View Replies
View Related
I want to be to call my menu from another file onto my page so that i dont have to add it to every page of my website. The problem is when i try to add it using the include method it says that only one include file is allowed on an ASP. The other include file is my connection string so i cant really take that out of the page because then nothing else will work!
How can i get the menu page included as well as the connecting string?
Have added the code below, i have highlighted the 2 include files that i want to use in blue, i have also left the div tag in for where i currently have the menu which is what i want to take out and have ther include file there instead, if that makes sense. Basically the bit in red i want to be able to remove from all of my pages and add the blue file above the red code in instead, but i dont know how!!!!! Code:
View Replies
View Related
How i can do <!--#include file="filename"--> dynamic with ASP, or any other way
View Replies
View Related
If I want to include a file to my webpage that is not placed in the same
folder asd the application, but in another folder on the same disk...
I found out that this is not going to work:
<!--#include virtual="D:/binaer.no/nova/test.asp"-->
Is there any other way to include from another domain account on the same
server?
There is going to be several applications that includes the same file, so
the trix ../../../ will not do it for me...
View Replies
View Related
<%
I am trying to use "set con" in the include file. i used it before with simple text but when I use the connection object it doesn t work. is this possible in asp and what is the problem with the code below:
inc.asp file
VARMSG = "set con = Server.CreateObject("ADODB.connection")"
con.Open ("dsn=project;uid=sa;pwd=sa")
%>
mainpage.asp
<!-- #include file="inc.asp" -->
<%
Response.write
set rsTypes = con.execute("select * from firstmarch order by cat")
%>
View Replies
View Related
Can someone advise how can I send an html message that include gif file using cdonts.
the gif cannot link to www, or any specific server location. user must be able to view when they open their email.no as attachment.
View Replies
View Related
I have asp page file0.asp which calls another asp page thru include. I have to set conditions tht....
originally the include should have file1.asp In the displayed file file1.asp user selects a hyperlink, it should take it as request and display the new file2.asp in same file0.asp in place of file1.asp.
so i want to display multiple pages on user request inside file0.asp. But originally when file0.asp loads it should have file1.asp. Code:
View Replies
View Related
how to include an asp file into an other asp file with checking condition first.I can do this easily in PHP, but in ASP, it seem that the content of included file is process before it read the code on page.So when I include a asp page into another asp page, I cannot choose which page will be include base on the condition.
View Replies
View Related
make a script for my forums (the header) involving the date and an included page. Quote:
If the month is 9 (September) then include page x
elseif the month is 10 (October) then include page y
else include page z
How do I go about doing that? I know how to do it in php, but I'm looking to do it with asp.
View Replies
View Related
I m trying to test an include example using the code below, but the page "aspsrc.asp" cannot be displayed.
--->aspsrc.inc page
<%
var msg = "testing testing"
%>
-->inc.asp page
<!-- include statement not to be placed within ASP delimiters -->
<!-- #include file=".aspsrc.inc" -->
<%
Response.Write( msg );
%>
View Replies
View Related
When I first started using Server Side Includes I used the regular file include:
Code:
<!--#include file = "myfile.asp"-->
Then I read where the virtual include is much beter. I figured I would try it out, so on my last project I used all virtual includes:
Code:
<!--#include virtual = "/somedirectory/somefile.asp"-->
It worked fine and I really couldn't tell any differnce. Maybe a little easier to remember where all the file needed to point to. But this was for a New Site so testing it on the server was easy. I didn't have to worry about existing content up there.
I'm now redesigning a site to add in some dynamic stuff and I always test everything on the server it will reside on to be sure everything will work. Typically I create a "v2" directory and run everything from there. Well this really screws me up when using a virtual include, becuase I would have to edit and then rededit all my file paths.
So my question is... What do you use? And why are file includes so bad?
View Replies
View Related
i'm calling an include file from within a <td> tag of an existing include file (i'm calling the adroator component from the head.asp file.
i'm getting the following error
Error Type:
MSWC.Adrotator (0x80004005)
ERROR Cannot load rotation schedule file
/root/includes/adrotator/adrotatorhomepage.asp, line 14
the include file head.asp is located in the includes directory while the ssi its calling is on the adrotator directory. here is the code for the adrotatorhomepage.asp (all relevant files are in the same directory) Code:
View Replies
View Related
I'm wondering if there's any way to include a XML file (with a XSL) in a ASP file? I've tried this <!--#include file="publications.xml"--> but the XML-code is included before it is formated according to the XSL and ends up being unformated.
View Replies
View Related
I'm trying to include a plain html file in my asp page, but don't know how to include since SSI is deactivated(?)
View Replies
View Related
how would i get something like this to work...
<!-- #include file="<%=Request.GetString("view")%>.txt" -->
i know wat i want and all but i can't figure out how to make it work.
View Replies
View Related