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?
I have an application that needs to pull files from an internal server. This is the setup. The web server is external facing, meaning exposed to the internet. I then have a file server that sits inside our domain. I created a COM object that can impersonate a user to retrieve files from that server. However, I cannot get the application to pull files from the internal server.
I first tried a domain account that could reach both servers. This did not work. I then had the network team create the same account on both machines. This is not working either. I can impersonate the user (I am able to get the user/users authenticated), but the script keeps coming back with and access denied. Code:
I've have a asp application that uses several session variables (login). I have a HTA application (on client "local") acting as the "window" for the application.
All works fine while using the HTA file to access my local version of the web application but when I try to access the same web application on the server with the same HTA file, just changing the iframe source from the client machine to the server, session variables no longer work. What's the deal? The server is not on our network, on DMZ. Code:
Our network administrator does not want to install the IIS SMTP server on our intranet. He wants me to use our existing SMTP server "mail.smpi.siemens.ca". Can I do this with IIS?? Is this a setting in an ASP if I'm not running the IIS SMTP 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
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?
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.
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.
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?
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?
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?
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:
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:
I am trying to display a random background image for a webpage. I found this code to do it
<% 'Defines the number of background images you have Const NUMBER_OF_IMAGES = 2
'Initiates the randomize function Randomize
'Sets a variable: this will be used to hold the 'random generated value Dim intImageNumber
'This is where we create the random number intImageNumber = Int((NUMBER_OF_IMAGES * Rnd) + 1) %>
Modify the body tag to accept the random number. In this case we are going to place it within the image so as to facilitate the selection of a random image. Code:
the DoConnection sub is in another page called MyDBConnection in a folder call Common.
I know that I can use serverside includes and embed my con in the page using <%%> but I want the use runat server How can I make call to a function in an external page?
I want to put the same JS tag on sites A and B that call an asp page on domain C.
The tag would look like this: <script language="JavaScript1.1" src="http://secure.C.com/Demo/Intercept.asp"></script>
The ASP page on domain C would write a cookie, in theory the cookie should have permissions for read and writing from site C. Something like this: Response.Cookies("Name").Expires = Date() + 365 Response.Cookies(SurveyName).Domain = ".C.com" Response.Cookies(SurveyName).Path = "/"
In firefox the result is exactly as planned, a cookie is set when a user goes to sites A or B via site C, and using this same approach, I can read the cookie from domains A and B via the JS tag calling the script on site C.
IE does not like this. Sometimes it doesn't even write the cookie, other times the cookie has to be there b/c of resulting actions taken, but when viewing the list of cookies, it's no where to be found. Additionally, I don't seem to be able to read the cookie the same way as firefox is letting me.
I know this can be done, I went to foodnetwork.com (yeah I love to cook), and saw that they were using a metric service that was calling a back end script from the vendors domain, and setting a cookie from that vendors domain, all without the user seeing anything or leaving the foodnetwork.com domain. I've looked at the resulting JS code that is returned from these vendor back end pages, and it has nothing to do with the cookie being set, it's definitely happening server side.
i am trying to write a script to parse an external xml file, but am having problems... the problem i think has to do with me trying to do Response.Write(xmlDoc.transformNode(xslDoc)) before the xml is fully loaded. The link to the xml file is valid. Code:
I have multiple websites on my Intranet. My current search engines can search within their own environment. However, I would like to have one search page, which retreives results from all environments.
My first task is to connect, retreive and display results from a second server (through http). Then I will need to scrub the results to display in a unique template.