First off hi all,
This is probably simple to someone but I'm stuck.
I created a button on a flash movie, .swf, insert it into a webpage created in Dreamweaver, the idea is when the button is clicked, a new browser window opens to a size of 600 x 600, no scroll bars to toolbar, just a way to close it. The browser will just contain a simple .jpg image of a map.
Now I've looked at heaps of sites and tried the following actionscript.
on (release) {
getURL("javascr ipt:openNewWind ow( \mysite\picture s\simple.jpg, height=600, width=600, toolbar=no, scrollbars=no );");
}
The above opens the browser and immediately closes again?????
As you can also see it's a relative site not an absolute site. It works fine if I use just getURL without the javascript stuff eg:
on (release) {
getURL("\mysite \pictures\simpl e.jpg", "_blank");
}
However it opens a new window "which is what I want" but it's obviously not sized to 600 x 600, and has scrollbars toolbar etc.
What am I doing wrong? I am TOTALLY new to FLASH and actionscript, and I am now more confused than ever, so your help would be appreciated
Hope all of the above makes sense!
Thanks in advance.
10 2813 kestrel 1,071
Recognized Expert Top Contributor
Hey, welcome to the scripts.
Try this on for size: -
var jscommand:String = "window.open('http://www.adobe.com','win','height=200,width=300,toolbar=no,scrollbars=yes');"; getURL("javascript:" + jscommand + " void(0);");
-
Thanks Kestrel,
It worked when I remembered to include the 'on release'
and {}. However I found I had to use the full WWW address, it wouldn't work with a relative address and also, It doesn't go right up into the corners. Leaves a gap at top of window and left side. Anyway of correcting that?
Thanks again!!
kestrel 1,071
Recognized Expert Top Contributor
Are you talking about the new window when it opens?
Sorry for the late reply,
yes when the new window opens to the size I set 600 x 600, the .jpg which is also 600 x 600 is not right up into the corner of the window there's a few pixels gap at the top and the left side of the image.
Also I noticed in IE7 browsers there's a drop down box that shows the full address of the .jpg. Anyway of fixing the 2 above issues?
Many thanks in advance.
kestrel 1,071
Recognized Expert Top Contributor
can i see your exact actionscript code, aswell as the html in your pop-up? that would help alot.
did you make sure that all your css styles are defaulted? on the page you are opening, put this in there
<style>
*, html {
border: 0 px;
padding: 0 px;
margin: 0 px;
}
</style>
obviously, remember to put these style tags in the html before you create the image. aka put them inside the <head> ... </head>
kestrel 1,071
Recognized Expert Top Contributor
Ok, so i created a pop up, and i also had that white space in the corner.
Your html popup page just has an image in it right? with <img />
Heres what i did - <img alt="" src="http://www.guitarzone.com/w-images/d/de/Pink_floyd_darkside.jpg" style="position: absolute; top: 0px; left: 0px;" />
That squares the image right up to the corner
Great thanks for your assistance everyone. And again so sorry for the tardy replies I don't have a heap of time to visit the site much.
Thanks again for ALL your time it is very much appreciated!
Sign in to post your reply or Sign up for a free account.
Similar topics |
by: Pieter |
last post by:
Hi,
I've a activex browser control in a form. I've added proxy server
support to the control by modifying the proxy server settings in the
registry. This works fine before the browser control is created (the
browser control is only created after a button on the form is pressed).
However, once the initial proxy settings are commited and the browser
control is created, the browser control does not respond to any new
settings even though...
|
by: michal2 |
last post by:
Is there any way to have the referring field blank when using the
GetURL command?
|
by: therefor |
last post by:
I have the following in Flash 8
BriefLook_mc.btnStudentLife_mc.onRelease = function():Void
{
this.createEmptyMovieClip("craveLoader_mc", this.getNextHighestDepth());
this.craveLoader_mc.getURL("BWC_Crave.swf", "_blank");
}
This opens a new window for BWC_Crave.swf ...like I want. But the window scales depending on my current window sizing. If I make my window bigger or smaller, it sizes the flash movie in the window. I want it...
|
by: camphor |
last post by:
hi,
I am getting this error message when using getURL
**Error** Symbol=contact, layer=text, frame=1:Line 1: Statement must appear within on handler
email_btn.onRelease = function(){
Total ActionScript Errors: 1 Reported Errors: 1
actionscript:
|
by: Atran |
last post by:
Hello EveryBody, I am new to ActionScript.
I make to my flash page a button, I want make the button open a web using getURL commnad.
See this code:
button1.onRelease = function(){
getURL("http://www.adobe.com/", "_blank");
}
When I export my project to a swf file, and run the swf from my directory, not from flash program. When the swf is running I click my button, flash show to me a messagebox that the url cannot be shown for...
| |
by: neliy |
last post by:
hello there. Well I actually have 2 small problems with getURL. I need to connect a button with a web site an my code looks like this:
on (release) {
getURL("http://www.blahblahblah", "_blank");
}
also I'm trying to make some pop ups work like this:
on (release) {
getURL("pops\1.htm", "_blank");
|
by: streammalvern |
last post by:
I'm working with a client's site where I have the header created in flash. The site is hosted by a third party and I have sent them the code for the flash header, which is hard coded to look for the swf on my company's server.
In the flash header I have an invisible box over the logo with a simple getURL, linking it back to the home page. This DID work when I tested it out in both IE and FF but now as of late the page doesn't go anywhere...
|
by: cstansbu |
last post by:
This is the item selection piece for a Sharepoint knowledge base. If you type a valid plan code you get info, but if you type garbage you get a 404 file not found. I want to check user input against an array of allowable values (eg. A33, B33, A80, B22, etc...) .
true = go to the topic you put in; false = go to a form similar to the original but alerting you to invalid entry.
Script:
<SCRIPT type=text/javascript>
/*
Navigate to...
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look !
Part I. Meaning of...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
|
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
| |
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules.
He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms.
Adolph will...
|
by: conductexam |
last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one.
At the time of converting from word file to html my equations which are in the word document file was convert into image.
Globals.ThisAddIn.Application.ActiveDocument.Select();...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
|
by: bsmnconsultancy |
last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...
| |