Wrox Programmer Forums
|
Javascript General Javascript discussions.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Javascript section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old July 21st, 2003, 03:14 PM
Friend of Wrox
 
Join Date: Jun 2003
Posts: 119
Thanks: 0
Thanked 1 Time in 1 Post
Default FullScreen question

I have a link in my ASP code that I would like to open in a new window but
open in FULLSCREEN mode. I have put in 2 pieces of code at the SCRIPT tag
and one at my link. When I click on the link I get a blank page. ANY
help, suggestions or direction would be appreciated. Here is my code:

CODE IN SCRIPT TAG:

<script LANGUAGE="JavaScript">
function fullScreen(theURL)
{
window.open(theURL, '', 'fullscreen=yes, scrollbars=auto');
}
</script>

CODE IN MY ASP CODE:

If
obj.HasAccess("/patient_center/Electronic_Signature_-_PHD_Medical_Record_Reports/dictaphone.asp")
Then

Response.Write "<p>"
Response.Write "<a href='javascript:void(0);' onClick='fullScreen('/patient_center/Electronic_Signature_-_PHD_Medical_Record_Reports/dictaphone.asp?u=" & stru & " target='_new')'>"
Response.Write "<b>Electronic Signature - PHD Medical Record Reports</b></a>"
Response.Write "<br>Access to ESig web based application.<br><br></p>"

End If


 
Old July 21st, 2003, 03:38 PM
Imar's Avatar
Wrox Author
 
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
Default

Hi there,

It seems you have mixed up some of your quotes in the statement.

Take a look at this:

Code:
onClick='fullScreen('/patient
As you can see, the second ' will close the code for the onclick handler. It's better to use double double quotes in ASP to send out a single double quote to the browser, like this:

Code:
onClick=""fullScreen('/patient
That way, you can use the single ' for JavaScript, and the double quotes for ASP strings.

Secondly, you shouldn't add the target attribute. Because you override the default behavior for the link, this makes no sense. Besides, the JavaScript function takes care of that.

HtH

Imar



---------------------------------------
Imar Spaanjaars
Everyone is unique, except for me.
 
Old July 22nd, 2003, 07:52 AM
Friend of Wrox
 
Join Date: Jun 2003
Posts: 119
Thanks: 0
Thanked 1 Time in 1 Post
Default

Thanks much for your help!!

Quote:
quote:Originally posted by Imar
 Hi there,

It seems you have mixed up some of your quotes in the statement.

Take a look at this:

Code:
onClick='fullScreen('/patient
As you can see, the second ' will close the code for the onclick handler. It's better to use double double quotes in ASP to send out a single double quote to the browser, like this:

Code:
onClick=""fullScreen('/patient
That way, you can use the single ' for JavaScript, and the double quotes for ASP strings.

Secondly, you shouldn't add the target attribute. Because you override the default behavior for the link, this makes no sense. Besides, the JavaScript function takes care of that.

HtH

Imar



---------------------------------------
Imar Spaanjaars
Everyone is unique, except for me.





Similar Threads
Thread Thread Starter Forum Replies Last Post
thanks but i have another question antony maiky CSS Cascading Style Sheets 1 August 20th, 2006 03:52 PM
Question Ashwini Classic ASP Databases 3 January 10th, 2006 07:20 AM
Question Ashwini Classic ASP Databases 2 January 5th, 2006 01:31 PM
Why doesn't this code open window to fullscreen? savoym Javascript 4 July 23rd, 2003 09:51 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.