Help with chromeless popup, please


I really like the borderless/chromeless popup shown on page

I’ve got it working with a Flash MX movie inside, but I’m still left with a white border down the left-hand side and along the top between the movie and the title bar. Any ideas what I need to change?

The width and height settings in the getURL action attached to the button are 550 x 400, but the borderless window is too big.



Replace [] with <>

That is what your body tag should look like (with any added body tag features you may have). This remove the margin on the top and left of your page so you will not have that white border. you can also do rightmargin=“0” and bottommargin=“0”, but for chromeless windows I don’t think it matters much.

It works great now. Thanks.

One other question: could you let me know if it’s possible to convert a png file to a gif, please?


Hmmm, I don’t know why you would want to do that, but if you were to, you could open it up in a graphics program (such as Photoshop) and then click Save As and save it as a .gif. This may cause distortion if you have some areas of partial transparency. .PNG is the only file type that is supportive of partial transparency, where .GIF can have completely transparent backgrounds, .PNG files can have it look like the image is at a low _alpha setting.

If you don’t have a graphics program to open up the file, you MIGHT be able to download an image file converter. But you have to make sure it supports the .png image type. You can try and find one at or something.


Thanks for the info about png conversion. I asked because I tried to open a png with Photoshop 5. The png is a ‘close’ button (the one with the cross), but it just appears as a black square in PS. In fact, I’ve used the png for the chromeless popup, but the X looks a bit pixelated - ragged and untidy. I thought maybe the gif would look better. It may, however, make no difference.

On another note, I’ve encountered a problem with the chromeless popup. Could you give me some suggestions to help solve it?

The Flash movie displayed is 550 x 400, but the chromeless popup crops the movie on the right-hand side.

The button has the following action:

on (release) {

I’ve tried increasing the width settings, but it made no difference. Could you suggest some way of solving the problem?

Also, is it possible to center the words in the title bar? Do I need to make some changes to the var tH variable? I tried using <div align> tags, but as they’re html I wasn’t surprised they didn’t work.


That is quite odd, did you publish your movie as exact size or did you change the width and height in the publish settings? Make sure the HTML EMBED code has the correct Width and Height settings. If that doesn’t work can you possible upload the pages and show me?

As far as I know you can’t center the title text, but I never really experimented with that, so I can’t say for sure.

Hi lostinbeta,

The movie plays fine in the html page and in an ordinary popup. For some reason the chromeless popup chops a few pixels off the right-hand side. I’ll play around with the settings to see if I can sort it out.

Afraid I can’t upload it: my site doesn’t have a host - yet.


Hey lostinbeta… There’s a great feature which lets you post code without the explination about changing ] for >

put code surounded by [ ] as beginning and end tags and you can write out the code normaly.

Congrats on the moderershipness thingy, :slight_smile:

Ok… now I need help with this. I need to make my popup dynamic so I am wondering 2 things.

A) this is my function

function launchNewWin (name) {
	getURL ("javascript:Launch('hollow.htm')");

I’d like it to be more dynamic, like this say

function launchNewWin (name) {
	getURL ("javascript:Launch(/"+variableName/".htm')");

However… the above method does not work. Neither does

function launchNewWin (variableName) {
	getURL ("javascript:Launch("+[variableName+'.htm']+")");

How could I do this?

My second question relates to the first.

The html page that has the java script takes sizes for the window. I was wondering if I could feed variables to the page with a loadVariables(); method and then place those variables in the height and width.

Hey david, thanks for the congrats:). Assuming you are using standard pop-up window code I am going to tell you that you can’t make it dynamic. :frowning:

I am working on a script where you could possibly define the page loading, height and width inside the < A > tag or the getURL in flash. So far, not too much luck…but I will keep working on it.

Basically what I am trying to do is only have 1 function in the html page, and then you can specify the width, height and what page you want to load inside your link. That way you don’t have to have a billion functions inside your HTML page to choose from, all with different sizes, etc.

**** it.

Thanks. I can stop workin on that for the moment then,

Hey david,

After reading this thread I got back onto working on that dynamic pop-up window script. I got it to work in a second. I made <B><I>THE</I></B> stupidest mistake in my code, I am always doing that! One little symbol can make or break your code, grrrrr:pirate:

Anyways, I am not going to say what I did wrong, it’s just too embarassing, I just wanted to let you know I got it working.

Attached I included a .zip file with a .fla of a flash button (stupid square button, I wasn’t about to waste my time making an intricate one), the .swf of the button, a .html file with the code and examples of both HTML links and the Flash button, and last but not least, a ReadMe.txt file, which I suggest reading, because I took the time to type it…haha.

I hope this helps you out david.