Home :: Forums :: Register :: Sign In :: Links :: Downloads :: Shop
You are not signed in. Please sign in. If you have not registered, please click here.

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   More...
#1Tue Dec 28, 2004 9:57 am   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 7 year's 7 Year Member
uk.gif
Occupation: Web Designer
Age: 33
Fav. Sports Team: Liverpool
Website: www.badassbrits.com
Status: Offline
Joined: Sep 02, 2004
0.03 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




_________________
Image
Back to top Reply with quote
#2Tue Dec 28, 2004 12:51 pm   re: Making A pop up for an swf for a certain size
Kelly_Hero
PayPal Donation
Asst. Admin
 Codezwiz Site Donator
Kelly_Hero has been a member for over 8 year's 8 Year Member
usa.gif southcarolina.gif
Occupation: Web Developer
Age: 47
Website: www.myleague.com/bandr
Status: Offline
Joined: Aug 20, 2003
1.18 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
#3Wed Dec 29, 2004 11:36 am   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 7 year's 7 Year Member
uk.gif
Occupation: Web Designer
Age: 33
Fav. Sports Team: Liverpool
Website: www.badassbrits.com
Status: Offline
Joined: Sep 02, 2004
0.03 posts per day
Posts: 92
Points: 10,111
   
Thx that sorted it Take a look let me know what ya think..




_________________
Image
Back to top Reply with quote
Display posts from previous:      
Add To: Del.icio.us  Digg  Google  Spurl  Blink  Furl  Y! MyWeb   More...
<< 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