NavigateToURL
Hi, I have a problem to display a file in a netscape window
with the method navigateToURL. It brings, in parameter, the url of
the file (it's path directory). It would be simple if this file was
in my flex project directory (indeed, url would be, for example,
url ="./pathDirectory/fileName.pdf").
But here, that file is not in my flex project but in the
temporary directory (for the loaded files from a web application)
Does anybody have an idea on how the url path should be to
access this file and display it in a netscape window ??
Thanks in advance
jnic
i think i got it..
I done a quick test with the information you give.
- I created a folder in my disk root
: c:\test
- I created a txt file :
test.txt
In my Application i put it :
<mx:Script>
<![CDATA[
import flash.net.*;
public function openMyPDF():void {
var u:URLRequest = new URLRequest("c:/test/test.txt");
navigateToURL(u,"_blank");
]]>
</mx:Script>
<mx:LinkButton label="Flex WhitePaper"
click="openMyPDF()"/>
Conclusion:
MX Application ->
C:\FlexWorkspace\cre_marcacao\bin\pdf.html
File to Open -> C:\test\test.txt
Ps: Make notice that when you Run your application is
deploy'it to the Bin folder, so you have to make a path that
returns all way back, anless you use a complet path like in sample
above. You don't wanna use a complet ? Try This Way:
<mx:Script>
<![CDATA[
import flash.net.*;
public function openMyPDF():void {
var u:URLRequest = new URLRequest("../../../test/test.txt");
navigateToURL(u,"_blank");
]]>
</mx:Script>
<mx:LinkButton label="Flex WhitePaper"
click="openMyPDF()"/>
Hope I Help ^^
[[]] Core
Similar Messages
-
Navigatetourl won't open in same window and in infinite refresh
I have a project that requires a skip button and to go to a specified url in the same window once the animation is complete. The button works, however the navigatetourl in the last frame is not behaving.
Here is the code I've placed in the last frame:
addEventListener(Event.ENTER_FRAME, fl_EnterFrameHandler);
function fl_EnterFrameHandler(event:Event):void
//Start your custom code
// This example code displays the words "Entered frame" in the Output panel.
navigateToURL(new URLRequest("http://www.student.nvcc.edu/home/amlayne/ite170/dreamweaver/graded_assignments/index.html"), "_self");
stop();
// End your custom code
I've tried moving it to an earlier frame, placing a stop in the earlier frame, moving the stop command to after and so on. No matter what I do, the new url opens in a new window and is in a constant state of refresh. I also have the loop turned off but the animation begins to load the first frame again anyway. Please help. I've tried many fixed listed in forums that are all about the same with no different results. You can view my animation here: http://www.student.nvcc.edu/home/amlayne/ite170/flash/graded%20assignments/myintro.html
NOTE: You will have to close the browser to get the refresh to stop.
I've been working on this one issue two days and am at a complete loss.Any thoughts on why my button now won't open in the same window? I'm getting a sense the built in code snippets don't work as they should, or I'm just making silly mistakes. Here's the code:
btnSkip1.addEventListener(MouseEvent.CLICK, fl_MouseClickHandler);
function fl_MouseClickHandler(event:MouseEvent):void
// Start your custom code
// This example code displays the words "Mouse clicked" in the Output panel.
navigateToURL(new URLRequest("http://www.student.nvcc.edu/home/amlayne/ite170/dreamweaver/graded_assignments/index.html"), "_self")
// End your custom code -
NavigateToURL not working on Mac Projector with Firefox as Default Browser
I'm making a CD with both a PC (exe) and Mac (app) projector file on it. I have a button that navigates the user to our client's website with the following code:
var webBtnURL:String = "http://www.clientswebsiteURL.com";
web_btn.addEventListener(MouseEvent.CLICK, gotoWebsite);
function gotoWebsite(e:MouseEvent):void
navigateToURL(new URLRequest(webBtnURL), "_blank");
This works perfectly on the PC projector file, with either Firefox or IE as the default browser. However, I've found that if Firefox is the default browser on the Mac side, it just opens Firefox and navigates to a blank page. If Safari is the default browser it works fine. The Mac I was testing this on was a PowerPC instead of an Intel Mac, so I don't know if that makes a difference or not, but it had the latest version of Firefox on it.
Any help would be appreciated.
Thanks.kglad wrote: otherwise, you can publish for air (in your publish settings).
I need to look more into Air. I just don't know much about it at the moment. What are its benefits? Would the end users need to have it on their computers or will it be packaged into the EXE just like the Flash Player is?
kglad wrote:
everyone that hasn't already set flashplayer security settings will be warned about a security sandbox issue and allowed the option to allow your file to access another file on the internet. if they chose to not allow that, your url will not open.
I don't recall having set any security setting for Flash on my Mac (although it's possible I did at some point) and I didn't get any options, just a blank webpage. If I were to go back into the Flash settings on my Mac, I may be able to allow the projector to open a website even when Firefox is the default browser?
Thanks. -
In Flex Application Session out while export to excel while using navigateToURL _Self ?
Hi,
I am using Flex 3.0 and facing one problem session out while export to excel in Live server not on localhost .
I have Used navigateToURL (url, "_self"); export to excel. While url is sevrlet call.
In localhost(tomcat) everything is working fine while another server or live in weblogic server, my session Is Getting Lost and User is re-directed to login screen again.
what to do to resolve this issue.
while I tried to use _blank instead of _self then session Is getting preserved but its opening blank new window which user will not accept necessary page.
please Suggest what to do to preserve The session while using _self ..
waiting for quick reply.
Regards,
prabhatI'm not using Flex, but the following preserves session in Flash:
var url = "http://" + WebServerIPAddress + "/" + ApplicationName + "?data=" + datavalue;
var cmd:String = "window.open('" + url + "','win','height=768,width=1024,toolbar=no,scrollbars=yes');";
var request:URLRequest = new URLRequest("javascript:" + cmd + " void(0);");
navigateToURL(request, "_self"); -
NavigateToURL() not working when trying to open a file.
Hi,
I am working on an AIR Flex application running on the local Windows system.
Following code works when accessing the file from my local system.
I want to display a file which is present in a remote server.
In ActionScript, The below code does NOT work.
var url:String = "\\<RemoteServerName>\d1\abc.pdf";
var request:URLRequest = new URLRequest(url);
flash.net.navigateToURL(request,
"_blank");
When I am trying to open the file manually, e.g. Start -> Run -> Open (\\<RemoteServerName>\d1\abc.pdf), the document opens fine.
Please let me know if there are any other way of opening a file from remote location.
Thank You,
SwayThanks rkewlani,
I think I am geting closer for a solution though I am getting a new error after changing the URL.
My new url:String looks like
var url:String = file:\\RemoteServerName\d1\abc.pdf;
var request:URLRequest = new URLRequest(url);
flash.net.navigateToURL(request,"_blank");
Error I get is :
SecurityError: Error #2121: Security sandbox violation: navigateToURL: app:/XXX.swf cannot access file:\\RemoteServerName\d1\abc.pdf;. This may be worked around by calling Security.allowDomain.
I added Security.allowDomain("*") to the creationComplete event of the form, Now the error is
SecurityError: Error #3207: Application-sandbox content cannot access this feature.
at flash.system::Security$/allowDomain()
Any help on this.
Thanks,
Sway -
I'm trying to do a loop, and call a javascript function in
flex for every loop.
The loop only seems to call the javascript once the loop is
done... and it only calls it for the last iteration of the loop.
To reproduce the issue do the following:
1. Create a new project in flex
2. Put a button on the form, and make it's click="test1();"
3. Create a script block like so
<mx:Script>
<![CDATA[
private function test1():void{
for (var i:int = 0; i < 5; i++){
var u:URLRequest = new URLRequest("javascript:alert(" +
"\'test " + i + "\');");
navigateToURL(u,"_self");
trace(i);
]]>
</mx:Script>
the button calls this very simple function, and theoretically
you should get 5 alert boxes, but you don't...you get 1.... i'm
curious if these methods can be used like this.have a look here: http://livedocs.adobe.com/flex/gumbo/html/WS2db454920e96a9e51e63e3d11c0bf626ae-7fe8.html
<s:Application
xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:mx="library://ns.adobe.com/flex/halo"
xmlns:s="library://ns.adobe.com/flex/spark">
<s:layout>
<s:HorizontalLayout/>
</s:layout>
<fx:Script><![CDATA[
import flash.net.navigateToURL;
private var listingData:Array=[
"http://flex.org",
"http://www.adobe.com",
"http://aspexamples.adobe.com"
private function openWindows(n: Number):void {
if (n < listingData.length) {
navigateToURL(new URLRequest(listingData[n]), '_blank');
callLater(callLater, [openWindows, [n+1]]);
]]></fx:Script>
<s:Button label="Click Me" click="openWindows(0)"/>
</s:Application> -
Opening PDF with navigateToUrl on Android
Hi,
i'm developping an enterprise application in AIR on Android which show a list of PDF's on your device and should open them when you press on it.
However, when using navigateToUrl for this purpose, it doesn't open the PDF in Adobe Reader (which is installed) but in another app, called HP IPrint.
Even uninstalling HP IPrint, setting Adobe Reader as the default app for reading PDF files doesn't change this behaviour. It either opens it in HP IPrint, or if IPrint is not available not at all. Opening the PDF from outside the AIR app with Adobe Reader works fine however.
Since openWithDefaultApplication is not supported under the mobile profile, how do I make AIR open PDF's in Adobe Reader?
Thx in advance.Do you have the latest version of Adobe Reader installed?
-Pahup -
Problem with navigateToURL to a certain frame
Hi!
I'm kinda new with Flash but I've managed to create a menu
for a homepage. Now when I click on one of the menu links - the
page opens up in a new window.
But I don't want that at all.
I want the page to open up in another frame called mainframe.
I've tried a number of things already; changing from
"mainframe" to "_mainframe" and back, trippelchecking that the
frames name really is mainframe so there's no typo. I've also
changed the name of the mainframe both in the htmlfile and the code
but that didn't work either.
Please help!
Here's my code:
1. var linkabout:URLRequest = new URLRequest("about.html");
2. //...//
3. function aboutClick(event: MouseEvent):void
4. {
5. if(subDown[1] == true)
6. {
7. //true = submenyn är nere o ska upp
8. subAbout_mc.gotoAndPlay(15);
9. stage.addEventListener(Event.ENTER_FRAME, subUpAbout);
10. }
11. else
12. {
13. //false = submenyn är uppe o ska ner
14. navigateToURL(linkAbout, "_mainframe");
15. btnHit[1] = true; //visar att det är denna sub som
ska ner
16. checkSubDown();
17. }
18. }quote:
Originally posted by:
kglad
copy and paste your html code and copy and paste your
navigateToURL() function along with any other code needed by your
function.
Sure:
------------------------AS---------------------------------------------
1. var linkabout:URLRequest = new URLRequest("about.html");
2. //...//
3. function aboutClick(event: MouseEvent):void
4. {
5. if(subDown[1] == true)
6. {
7. //true = submenyn är nere o ska upp
8. subAbout_mc.gotoAndPlay(15);
9. stage.addEventListener(Event.ENTER_FRAME, subUpAbout);
10. }
11. else
12. {
13. //false = submenyn är uppe o ska ner
14. navigateToURL(linkAbout, "mainframe");
15. btnHit[1] = true; //visar att det är denna sub som
ska ner
16. checkSubDown();
17. }
18. }
------------------------XHTMLcode---------------------------------------------
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0
Transitional//EN" "
http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="
http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html;
charset=utf-8" />
<title>Untitled Document</title>
<link href="_css/maincss.css" rel="stylesheet"
type="text/css" /><!--[if IE 5]>
<style type="text/css">
.twoColFixLtHdr #sidebar1 { width: 230px; }
</style>
<![endif]--><!--[if IE]>
<style type="text/css">
.twoColFixLtHdr #sidebar1 { padding-top: 30px; }
.twoColFixLtHdr #mainContent { zoom: 1; }
</style>
<![endif]-->
<script src="Scripts/swfobject_modified.js"
type="text/javascript"></script>
</head>
<body>
<h1>nih<span
id="headerh1orange">.</span>com</h1>
<object
classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" width="100"
height="180" hspace="0" vspace="0" align="left" id="FlashID"
title="menu">
<param name="movie" value="Scripts/menu/menu_idaway.swf"
/>
<param name="quality" value="high" />
<param name="wmode" value="opaque" />
<param name="swfversion" value="9.0.45.0" />
<!-- This param tag prompts users with Flash Player 6.0
r65 and higher to download the latest version of Flash Player.
Delete it if you don’t want users to see the prompt. -->
<param name="expressinstall"
value="Scripts/expressInstall.swf" />
<!-- Next object tag is for non-IE browsers. So hide it
from IE using IECC. -->
<!--[if !IE]>-->
<object data="Scripts/menu/menu_idaway.swf"
type="application/x-shockwave-flash" width="100" height="180"
hspace="0" vspace="0" align="left">
<!--<![endif]-->
<param name="quality" value="high" />
<param name="wmode" value="opaque" />
<param name="swfversion" value="9.0.45.0" />
<param name="expressinstall"
value="Scripts/expressInstall.swf" />
<!-- The browser displays the following alternative
content for users with Flash Player 6.0 and older. -->
<div>
<h4>Content on this page requires a newer version of
Adobe Flash Player.</h4>
<p><a href="
http://www.adobe.com/go/getflashplayer"><img
src="
http://www.adobe.com/images/shared/download_buttons/get_flash_player.gif"
alt="Get Adobe Flash player" width="112" height="33"
/></a></p>
</div>
<!--[if !IE]>-->
</object>
<!--<![endif]-->
</object>
<!--</div>-->
<div id="mainContent" align="left">
<iframe id="mainframe" src ="news.html" width="910"
height="700" frameborder="1">
</iframe>
</div>
<script type="text/javascript">
<!--
swfobject.registerObject("FlashID");
//-->
</script>
</body>
</html>
The flashmovie is the menu. When the Aboutlink is klicked I
want the target to be my iframe mainframe - located in my div
mainContent. -
Use navigateToURL to open a local pdf...
I have a problem with the following code. I have been searching since yesterday for solutions to open pdfs in a browser window from within flash. I've found various forum posts about using navigateToURL and it looks like people have success. It seems very simple to do, but everytime I try to open the pdf file, i get a 404 error in the browser, which is going to this link:
http://file.pdf (which obviously does not exist)
My pdf file is sitting inside the same folder as the swf that's trying to launch it. Is there a way to use navigateToURL and specify that the file is local? Else, is there another way to open a pdf file from within a folder? Or am I just an idiot and am missing something very obvious?
Thanks for any help,
Chipleh
Code:
myBtn.addEventListener(MouseEvent.MOUSE_DOWN, openPDF);
function openPDF(event:MouseEvent):void{
var url:String = "file.pdf";
var myRequest:URLRequest = new URLRequest(url);
try {
navigateToURL(myRequest, '_blank');
catch (e:Error) {
trace("Error occurred!");Hakan KIRIK wrote: "Have you tried Windows Projector (from publish settings) ?"
Sweeeeet! That works great Hakan, we can certainly use the Flash Projector.
One more solution I just came up with through googler(in case anyone is interested)
- Create a .bat file and call it from fscommand:
In Flash:
function openPdf(event:MouseEvent):void{
fscommand("exec", "openPdf.bat");
In your fscommand folder:
Create a .bat file called openPdf.bat with the following contents:
@echo off
file.pdf
exit
For this solution to work, name your pdf 'file.pdf', or change the name in the bat file and place the pdf in your fscommand folder as well.
However, it's alot more work than just calling the navigateToURL funtion, but if you don't want to use a web browser to display your pdf, then the bat file method will work.
Thanks for the solution Hakan, much appreciation,
~Chipleh -
Bug in navigateToURL? (AIR HTML/JavaScript) window name parameter not working
Hi,
I have to popup the default browser from a HTML/JavaScript application.
All links on the Air page should be opened in the same tab in the same browser window that was opened by the first click on a link.
The code I use is
var urlString = "http://www.adobe.com";
var request = new air.URLRequest(urlString);
air.navigateToURL(request, "myNewWindow");
The myNewWindow parameter does not seem to be taken into account: a new tab is opened on every click.
I created a new Air application in Aptana and added the following straightforward code to it:
<html>
<head>
<title>navigateToURLTest</title>
<script type="text/javascript" src="lib/air/AIRAliases.js"></script>
</head>
<body>
<a href="http://www.google.com"
onclick="javascript:air.navigateToURL(new air.URLRequest('http://www.adobe.com'), 'AirTestWindow');return false;">New Tab</a>
<br />
<a href="http://www.adobe.com"
onclick="javascript:air.navigateToURL(new air.URLRequest('http://www.adobe.com'), 'AirTestWindow');return false;">Same Tab</a>
</body>
</html>
Same problem.
Does anyone have any idea?
ThanksIs there really nobody who can answer or at least try to reproduce this?
It's just creating a new Air HTML/Javascript application with one link with a named window target! -
Isn't it possible to send Html Mail through navigateToUrl() with contentType "text/html" for Android ? please suggest any workaround
ThanksAHHHH
What you can do to make HTML for Apple Mail is to make it in an HTML editor, open it with Safari use CMD+i - a new mail message will appear in a moment with the web page in the email body.
You can't do any major editing in Mail, you'll have to go back to the HTML file. But it works.
You can also use Copy (from a web page) and then (Edit) Paste as HTML (that what Paste as HTML is for, not for creating HTML email). You can also user Paste as HTML to copy/paste a HTML email you receive or part of a HTML email. -
Send html mail with navigateToURL(new URLRequest('mailto:
hi!
do you think its possible, to send html text to the email client of the mobile device?
i tried different ways, but without success.
Way 1
navigateToURL(new URLRequest('mailto:[email protected]'+'?subject=Subject'+'&body= <html><body>Hello world<br><img src="http://www.republicofcode.com/wp-content/uploads/2012/04/Pins2_300_250.png"></body></html>'));
Way 2
var hdr:URLRequestHeader = new URLRequestHeader("Content-type", "text/html");
var request:URLRequest = new URLRequest('mailto:[email protected]?subject=Subject&body=<html><body>Hello world<br><img src="http://www.republicofcode.com/wp-content/uploads/2012/04/Pins2_300_250.png"></body></html>');
request.requestHeaders.push(hdr);
navigateToURL(request);
Maybe i need another content type than text/html?
In the reference i've read, that the default one is: application/x-www-form-urlencoded
http://help.adobe.com/de_DE/FlashPlatform/reference/actionscript/3/flash/net/URLRequest.ht ml#contentType
Any ideas?you could try:
function submitPoll(e:MouseEvent):void {
//sending the email stuff
var request:URLRequest = new URLRequest("mailto:[email protected]"+"?subject=Subject"+"&body= Hello world ");
navigateToURL(request, "_blank");
request.method = URLRequestMethod.POST; -
ActionScript 3 - XML - NavigateToURL
Ok there are many tutorials out there on how to use this function, what I am trying to do and can't seem to find a tutorial on is using navigateToURL with the "mailto" email address being populated from an XML list.
For example you have a list of offices and each office has a lead. I want to populate a List component with the office name, and when clicked I want it to open the email client and populate the To: and Subject line from the xml file.
What I have so far populates the Office name into the list and when clicked the mail client will open but doesnt populate the To because I can't figure it out.
I believe I need to specify a var to pull the email address from the xml list, I just cant seem to get it right.
here is a snippet example of my xml code
<officeleads>
<office>
<officenm>PDX</officenm>
<emllink>[email protected]</emllink> <-------- I want this to populate the "To:" in an email
</office>
</officeleads>
and here is my ActionScript
var leadloader:URLLoader = new URLLoader();
leadloader.addEventListener(Event.COMPLETE, onLoaded);
leadlist.addEventListener(Event.CHANGE, openMailClient);
function openMailClient(l:Event):void
var request:URLRequest = new URLRequest();
request.url="mailto:" <---------- this is where I know I need to somehow specify the emllink in the xml file to be filled into the "To:"
navigateToURL(request,"Self");
var xml:XML;
function onLoaded (l:Event):void
xml = new XML(l.target.data);
var offlst:XMLList = xml.office;
for (var i:uint=0; i<offlst.length();i++)
leadlist.addItem({data:offlst.officenm.text()[i],
label:offlst.officenm.text()[i]});
leadloader.load(new URLRequest("officeleads.xml"));
Any help will be greatly appreciated.
Thanks
Sam
AS3 Noobtry:
import fl.events.ListEvent;
var leadloader:URLLoader = new URLLoader();
leadloader.addEventListener(Event.COMPLETE, onLoaded);
leadlist.addEventListener(ListEvent.ITEM_CLICK, openMailClient);
function openMailClient(e:ListEvent):void {
var request:URLRequest=new URLRequest("mailto:"+leadlist.getItemAt(int(e.rowIndex)).data);
navigateToURL(request,"_self");
var xml:XML;
function onLoaded(l:Event):void {
xml = new XML(l.target.data);
var offlst:XMLList = xml.office;
for (var i:uint=0; i<offlst.length(); i++) {
leadlist.addItem({data:offlst.emllink.text()[i],
label:offlst.officenm.text()[i]});
leadloader.load(new URLRequest("officeleads.xml")); -
NavigatetoURL is not working properly
I am using a single command getURL in my project It is a
simple Menu template that has some animated buttons.On clicking
they will get the required URL.I am using Flash 9 that is AS 3.0
version.
At first the Links are not working in IE and working best in
Mozilla.I found that a tag in OBJECT embed
statement.allosripaccess= always.then It was solved.Now It is
causing problem in Mozilla new version 3.0.The animation is
working.But that navigateToURl is not fetching the required Web
pages.The Links are silent.No action is there.I am unable to
scratch the Mystery.
If Anybody could solve it, i am so thanfull.From the
begening the getURL is a rough function in flash ActionScript
Kit.Now in As 3 only name is changed.I don't know Why the developrs
of ActionScrip Left it with such ambigous functionality.Hi
i have xml driven menu which uses navigateToUrl. evrithing is ok when i press ctrl+Enter and publish swf. It navigates to the url which is specified in menu.xml.But when i upload swf to website it is not working, navigates to like directory not a url.
ex. on local swf navigates to "sites URL"
on web site navigates "/" sign to mydomain/"sites URL" (error404)
please help to solve this
here is my as3 script and xml
<?xml version="1.0" encoding="utf-8"?>
<menu>
<item>
<posNum>1</posNum>
<label>label1</label>
<linkTo>link1</linkTo>
</item>
<item>
<posNum>2</posNum>
<label>label2</label>
<linkTo>link2</linkTo>
</item>
</menu>
//---------XML-MENU----//
var xmlPath:String = "menu.xml";
var xml:XML;
var loader = new URLLoader();
loader.load(new URLRequest(xmlPath));
loader.addEventListener(Event.COMPLETE, xmlLoaded);
function xmlLoaded(e:Event):void {
if ((e.target as URLLoader) != null )
{ xml = new XML(loader.data); createMenu(); } }
var numberOfItems:uint = 0;
function createMenu():void {
numberOfItems = xml..item.length();
var count:uint = 0;
var xPos:Number =61;
for each (var item:XML in xml.item) {
var menuItem:ButtonEffect = new ButtonEffect();
menuItem.name = "btn"+item.posNum;
menuItem.x = xPos xPos += menuItem.width-3.15;
menuItem.y = 82;
menuItem.menuText.txtb.text = item.label;
menuItem.menuTextw.txtw.text = item.label;
menuItem.linkTo = item.linkTo;
menuItem.mouseChildren = false;
menuItem.buttonMode = true;
addChild(menuItem);
menuItem.alpha =100;
count++;
menuItem.addEventListener(MouseEvent.CLICK, itemClicked);
function itemClicked(event:MouseEvent):void {
var yyy:String = event.target.linkTo;
var url:URLRequest = new URLRequest(yyy);
navigateToURL(new URLRequest(yyy),"_self");
trace(yyy); } } } -
Can't get navigatetourl to work
i've created a flash animation with as3. at the end of the
timeline i've got a stop(); action on the last frame which is
working just fine. on the following frame i have the navigatetourl
action navigateToURL(new URLRequest("
http://www.mydomain.com/menu.html"),
"_self"); for some reason which i've been incapable of figuring out
it will not automatically flip to the page i have written in my
action when the animation has finished playing. can someone please
let me know what i'm missing? geturl was soooo much easier back in
the day. thanks in advance!yes the stop and navigate actions are on the same frame. i
just tested it out of dreamweaver and i received an error about
flash trying to communicate with an unknown url or some such anyway
it took me to "Global security settings for content creators" on
adobe's site. i had to actually list the url that i wanted the
animation to go to as safe. good heaven's! all that time wasted
just to find out i had to change some settings on adobe's site.
ridiculous!!! any of you ever get that error or know about the
global security settings? just in case anyone else can't get the
navigate url to work changing that setting seemed to work. -
I am having an issue with using the navigateToUrl method when developing for the IOS using Flash Pro.
I am using the Addthis.com functionality to share things to twitter, facebook, etc. I use their api, which is actually super simple and just utilizes the navigatetourl method. When I test the method normally, it will successfully open up the iphone / ipod browser and navigate to the page. However, when I use it via the addthis class, clicking on the button to open the browser simply does nothing. The only real difference in how I tested it and the addthis work is that the addthis calls an additional class which then calls the navigateToUrl.
So my question would be "Does calling a class that does not initiate the navigatetoUrl method directly somehow break the method in IOS?" Using the same exact structure works 10)% in Air for Android btw.
Test code:
var request:URLRequest = new URLRequest("http://www.google.com");
navigateToURL(request);
addThis Code:
private function addThisToFacebook(e:MouseEvent):void{
var share_url:String = "http://www.google.com";
trace("Facebook Share Hit");
api.share(share_url, 'facebook');
in the api class, the code is called up here:
This is addThis.com api's code
public function share( url:String, destination:String='menu', options:Object=null ):void {
options ||= {};
var params:URLVariables = new URLVariables();
for (var k:String in DEFAULT_OPTIONS)
if ( DEFAULT_OPTIONS[k] || options[k] )
params[k] = options[k] || DEFAULT_OPTIONS[k];
params.url = url;
if ( stage ) {
if ( params.width == -1 )
params.width = stage.stageWidth;
if ( params.height == -1 )
params.height = stage.stageHeight;
if ( username )
params.username = username;
if ( destination == 'menu' )
destination = '';
var request:URLRequest = new URLRequest(ENDPOINT + (destination ? '/' + destination : '') + '/offer');
request.data = params;
navigateToURL(request, '_blank');
Is there something I can do/add for the navigateToUrl to work in IOS?Hi,
Yes, that's reproducible at our end.
Thanks for reporting the issue,we're looking into the issue.
-Pahup
Adobe AIR
Maybe you are looking for
-
Brand New Iphone 5s Home Screen display defect
Here goes my ordeal with my Iphone 5s upgrade After waiting in line for over an hour I purchased the Iphone 5s yesterday at Best Buy (Stonebriar, Frisco, TX). Later that evening, I noticed that when the time was 5:36, the home screen display was not
-
How to retreive all unconsumed messages from a topic with a MDB?
Hello! I have a webapp that stores TextMessages in a Topic in WebLogic. I have an ejbapp (Message driven bean) that reads messages from the topic. If both are up and running the ejbapp reads all messages sent from the webapp to the topic. But if I st
-
Opacity Masks in cs4 can't find layers with main objects on it.
I created image with flag and did clipping mask with some text. Now when I do a opacity mask my other layers disappear and i can't seem to bring them back. I use the transparency to mask and clip. After that my layers with the first original items I
-
Multiple WDS APs on a single IP range
I have 80+ APs on a single IP range. Can I have two WDS APs on a single IP range in order to service the 80+ APs? I was planning to configure 40 APs to point to one WDS AP and the other 40 to the other WDS AP
-
How do I just have a video as my theme?
How do I just have a video as my theme? I don't want any of these themes, I just want a video to play full screen in the background while you're selecting buttons etc... Can this be done?