473,385 Members | 1,546 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

Conflict in ASP vs Javascript

I am not sure if this is the right forum to post about this problem , but , i just want to discuss a problem i recently encountered.

I was developing a page in ASP , where i came across a problem.

The last few lines of code were like this :

'------ Popup page
response.write("<script language=javascript>alert('Hello')</script>")
response.write("<script language=javascript>window.open('nlok.php?UserName ="&UserName&"&Email="&Email&"','','width=600,heigh t=600,left=50,top=50,screenX=0,screenY=100,resizab le=yes,status=no,menubar=no')</script>")

Response.Redirect"registered.asp"

Despite of the code being perfect , the popup wasnt loading.

I then realized the possibility . The ASP Redirect wasnt giving the time required by Javascript to process the popup.

I hence decided to replace Response.Redirect with Javascript command to forward the page:

response.write("<script language=javascript>window.open('registered.asp',' _self')</script>")

It was working perfectly fine , but then another blow , I E 7 wasnt allowing this redirect , and i do not know why.

The solution i have in mind is , to place a PAUSE between ASP Redirect and the JAVASCRIPT popup code .

I know about some free components which can help me achieve this , but i am willing to do it without use of any external component.

I welcome any response.

Thanks.

Rahul Agrawal
Developer
Web2003 Corporation
www.web2003corp.com
Jan 2 '07 #1
1 4352
b1randon
171 Expert 100+
I am not sure if this is the right forum to post about this problem , but , i just want to discuss a problem i recently encountered.

I was developing a page in ASP , where i came across a problem.

The last few lines of code were like this :

'------ Popup page
response.write("<script language=javascript>alert('Hello')</script>")
response.write("<script language=javascript>window.open('nlok.php?UserName ="&UserName&"&Email="&Email&"','','width=600,heigh t=600,left=50,top=50,screenX=0,screenY=100,resizab le=yes,status=no,menubar=no')</script>")

Response.Redirect"registered.asp"

Despite of the code being perfect , the popup wasnt loading.

I then realized the possibility . The ASP Redirect wasnt giving the time required by Javascript to process the popup.

I hence decided to replace Response.Redirect with Javascript command to forward the page:

response.write("<script language=javascript>window.open('registered.asp',' _self')</script>")

It was working perfectly fine , but then another blow , I E 7 wasnt allowing this redirect , and i do not know why.

The solution i have in mind is , to place a PAUSE between ASP Redirect and the JAVASCRIPT popup code .

I know about some free components which can help me achieve this , but i am willing to do it without use of any external component.

I welcome any response.

Thanks.

Rahul Agrawal
Developer
Web2003 Corporation
www.web2003corp.com
Rahul, you should use javascript to do your redirect, not asp. That will help you to be sure that your javascript is executed. You'll want to use window.location() to move the browser to a new url. Also, window.setTimeout() will let you cause the javascript to sleep for a few seconds before forwarding. Give it a shot using those methods and I will help you if you run into a snag.
Jan 2 '07 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

3
by: P Wolpert | last post by:
This is my first post. I hope I don't sound stupid. I have a script conflict when I put two scripts on one page. Both scripts will work if I use one at a time but the menu button script will not...
2
by: loquini | last post by:
Hi, I'm using this piece of code, both scripts work fine separately but together only works the second one, How can I solve this conflict??? plss help me <body> <div id="watermarklogo"...
0
by: Caesar Augustus | last post by:
I'm having a problem with two different javascript controls in my app. The first chuck of javascript that I pasted into my app is the client-side calendar control popup which works fine when first...
1
by: Michael Repucci | last post by:
Hi all, minor newbie problem I hope you can help with, since I can't find the topic covered on line. Basically, I have a div section in my xhtml that I want visible for print (div {display:...
13
by: mudgen | last post by:
I have a webpage that has two flash animations running. I also have a javascript script running that rotates 3 images and fades them in and out. To do the fading and rotating in javascript I am...
14
Webwench
by: Webwench | last post by:
I am trying to run a simple script- (I'm just learning javascrpt) that uses a set of buttons to change the background and foreground colors of a web page. Some of the text on the page uses the css...
14
lotus18
by: lotus18 | last post by:
Hello World I have a problem in detecting the conflict schedule (Day and Time). Day 1. M 2. T 3. W 4. TH 5. F
14
lotus18
by: lotus18 | last post by:
Hello all I have these records on my Day Table for my complete database table please click here 1. M 2. T 3. W 4. TH 5. F 6. S
1
by: xhunter | last post by:
I have been working on this for some time and I came to the conclusion that I have no idea what is the problem, I am sure it should be something simple that I am overlooking, but I can't figure...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.