Solved

server name in window.open

Posted on 2011-09-27
1
256 Views
Last Modified: 2012-05-12
Hi everyone, I'm using a script command in my ASP intranet page.   The command is simple:

<script>window.open("myfilename.asp","mywindow")</script>

All was working fine until I have change my server name from "svradm" to "srvhadm" because when using window.open command, it tries to open the file in "srvadm".  

I need this command to open the right file or, at leat, that I can specify where the file is located?   Even when specifying directly svrhadm:80 in the code, it still doesn't wan't to open the file on the new server.

My feeling  is that there is some kind of variable I need to set in windows on my server but I have no idea where.

thank you for helping
0
Comment
Question by:Buropro-Citation
1 Comment
 
LVL 11

Accepted Solution

by:
MacAnthony earned 500 total points
ID: 36712313
If you have a <base href="svradmn"> attribute on the header of the page this could cause the issue. Normally window.open should try and open it using the current page's host if a relative path is supplied. If you used window.open('http://srvhadm/myfilename.asp','mywindow'), that should work as well.
0

Featured Post

PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
HTTPS jquery doesn't work 9 61
Jquery GMAP3 Hierarchy 1 27
HTML5 frame 5 25
how can i get the string decoded ? 2 12
This article will give core knowledge of JavaScript and will head in to your first JavaScript program. I am Durvesh Naik and I am here to deal with this series of JavaScript. I will teach you JavaScript in part wise , as its quite boring to read big…
Nothing in an HTTP request can be trusted, including HTTP headers and form data.  A form token is a tool that can be used to guard against request forgeries (CSRF).  This article shows an improved approach to form tokens, making it more difficult to…
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…

770 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question