Solved

SWF Button that will open a new browser window and resize, remove menu, toolbar etc

Posted on 2006-11-13
8
310 Views
Last Modified: 2012-08-14
Hi, I've not really used Flash but know that if I'm to achieve what I'm trying to do this is most likely the only thing that will do it.

I have a myspace.com account and the profile page is customisable to a point. DHTML/HTML and CSS are allowed but Javascript is disabled and not allowed. Also the IFrame and Object tags in HTML are not allowed. I can however use the Embed tag to Embed SWF files.

So, is it possible to have an SWF file that I Embed into the HTML without using any of the above restrictions that would allow me to open a new browser window, resize it, remove toolbar, menu, address bar etc?

I'm only putting 20 points into this post as I don't expect a soloution but if you think it's possible and you could provide all the help I need I'll post another thread with as much points as I can.

Thanks in advance
0
Comment
Question by:Tezdread
  • 4
  • 2
  • 2
8 Comments
 
LVL 17

Expert Comment

by:Dushan911
Comment Utility
As I know, we cant not do with only Flash. We should use Flash with Java script.

BR Dushan
0
 
LVL 1

Author Comment

by:Tezdread
Comment Utility
But can the Javascript be added into the Actionscript for the button and therefore remove the need to have any Javascript in the HTML page? The problem isn't using Javascript it just can't be in the HTML page. So if the Javascript can be put in the Actionscript and then the whole Flash file save as an SWF file this could be embeded into the HTML and resolve the issue.

I saw somewhere else that this 'might' be possible using Actionscript and getURL or ExternalInterface but like I said I don't really know Flash and certainly don't know anything about Actionscript :-/

Thnaks
0
 
LVL 17

Expert Comment

by:Dushan911
Comment Utility
We can use JavaScript inside our Flash Action scirpt. You can have an idea from following video.

http://www.kirupa.com/developer/flash8/video/popUpWindows.htm


BR Dushan
0
 
LVL 1

Author Comment

by:Tezdread
Comment Utility
Thanks for that. The problem with that is that it still has the Javascript in the HTML which will not work.

Can the Javascript be embeded into the Actionscript so that there is no Javascript in the HTML?
0
What Is Threat Intelligence?

Threat intelligence is often discussed, but rarely understood. Starting with a precise definition, along with clear business goals, is essential.

 
LVL 7

Expert Comment

by:muxxter
Comment Utility
Hi Tezdread.

Flash has a function called getURL. It can create a new window, but without Javascript, I'm afraid you can't resize, remove the toolbar, etc.
But it's a good place to start:

getURL("http://www.someplace.com/blah.html", "_blank");

That will pop a new window. See the Flash help page for more info.

Gav
0
 
LVL 1

Author Comment

by:Tezdread
Comment Utility
Thanks muxxter. the thing is, getURL("http://www.someplace.com/blah.html", "_blank");
is no different that having a standard HTML link using the target="_blank"

If I was to have a working Javascript that opens and resizes a browser window using HTML, would this Javascript be able to be removed from the HTML page and inserted directly into the Actionscript and perform the same operation?

If I can't use Javascript in the Actionscript then what I'm trying to achieve isn't going to be possible...
0
 
LVL 7

Accepted Solution

by:
muxxter earned 20 total points
Comment Utility
Yep.

In getURL you can put Javascript:

getURL("JavaScript:window.open('http://www.javascript-coder.com','mywindow','location=1,status=1,scrollbars=1,width=100,height=100');");

So, anything you can put in the open method, you can have Flash call.
0
 
LVL 1

Author Comment

by:Tezdread
Comment Utility
ah that's sound I'll give you the 20 points because that perfectly answers the question! and will start a new post with my remaining points because I'm gonna need some help in getting this to work. I have tried but I get errors and when I click the button in the browser nothing happens...thanks again!
0

Featured Post

Why You Should Analyze Threat Actor TTPs

After years of analyzing threat actor behavior, it’s become clear that at any given time there are specific tactics, techniques, and procedures (TTPs) that are particularly prevalent. By analyzing and understanding these TTPs, you can dramatically enhance your security program.

Join & Write a Comment

This is intended to introduce all collision detection principles in flash, their strengths, weaknesses and workarounds. The main method for Collision Detection in flash is using hitTestObject. But unless you'll be pushing rectangular shapes without …
In my long career of working as an actionscript developer, I had spent sleepless night often working hard to solve some small problems which actually took a lot of my development time; later found out the solutions to be a line or two. Here are s…
In this tutorial viewers will learn how to create a basic motion tween animation in Flash Open a new document in Flash: Draw/import an image: Press CTRL + F8 to convert it into a graphic symbol: Select a frame (how long you want the tween to last): …
The goal of the tutorial is to teach the user how to live broadcast using Flash Media Live Encoder and connecting it to YouTube to broadcast. Log into your Youtube account, choose live stream settings, start live stream from Flash Media Live Enc…

771 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now