Making A pop up for an swf for a certain size

  Post new topicReply to topicPrintable Version
<< View previous topic View next topic >>
Share: Del.icio.us  Digg  Google  Spurl  Blink  Furl  Y! MyWeb  
#1   Making A pop up for an swf for a certain size
Neoszion
CZ Super Newbie
 Codezwiz Site Donator
Neoszion has been a member for over 20 year's 20 Year Member
uk.gif
Occupation: Web Designer
Age: 45
Gender: Male
Fav. Sports Team: Liverpool
Website:
Status: Offline
Joined: Sep 02, 2004
0.01 posts per day
Posts: 92
Points: 10,111
   
Hi there all,
Im making a splash screen for my site and on one of the pics for it I want to link to a pop up. When the pop up comes up it is an swf now I want it to be a certain size so that I do not loose quality the size I want is 766X660 if anyone could help I would be realy gratefull..

BTW I had a look through some of the js downloads they worked but they didnt resize icon_wink.gif




_________________
Back to top Reply with quote
#2   re: Making A pop up for an swf for a certain size
Kelly_Hero
PayPal Donation
CZ Revered Member
 Codezwiz Site Donator
usa.gif southcarolina.gif
Occupation: Web Developer
Age: 59
Gender: Female
Website:
Status: Offline
Joined: Aug 20, 2003
0.48 posts per day
Posts: 3765
Points: 351,412
   
Here's a pop up script that allows you to specify the size of the pop up window. Put the following code into your <head></head> section:

<s cript language=Javascript>
function centerPopUp( url, name, width, height, scrollbars ) {

if( scrollbars == null ) scrollbars = "0"

str  = "";
str += "resizable=1,";
str += "scrollbars=" + scrollbars + ",";
str += "width=" + width + ",";
str += "height=" + height + ",";

if ( window.screen ) {
var ah = screen.availHeight - 30;
var aw = screen.availWidth - 10;

var xc = ( aw - width ) / 2;
var yc = ( ah - height ) / 2;
str += ",left=" + xc + ",screenX=" + xc;
str += ",top=" + yc + ",screenY=" + yc;
}
window.open( url, name, str );
}
</s cript>


The following code goes wherever your link is in your page:
<a href="javascript:centerPopUp('YOUR_PAGE.HTML', 'popup', 650, 575)">YOUR LINK</a>


Change the link URL, width and height and the link text to suit your needs.


Back to top Reply with quote
#3   re: Making A pop up for an swf for a certain size
Neoszion
CZ Super Newbie
 Codezwiz Site Donator
Neoszion has been a member for over 20 year's 20 Year Member
uk.gif
Occupation: Web Designer
Age: 45
Gender: Male
Fav. Sports Team: Liverpool
Website:
Status: Offline
Joined: Sep 02, 2004
0.01 posts per day
Posts: 92
Points: 10,111
   
Thx that sorted it Take a look let me know what ya think..




_________________
Back to top Reply with quote
Display posts from previous:      
Add To: Del.icio.us  Digg  Google  Spurl  Blink  Furl  Y! MyWeb  
<< View previous topic View next topic >>
Post new topicReply to topic

Jump to 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You cannot download files in this forum