Search Results

Search found 1096 results on 44 pages for 'swf decompiler'.

Page 24/44 | < Previous Page | 20 21 22 23 24 25 26 27 28 29 30 31  | Next Page >

  • How to remove "index.php?" from HTACCESS [duplicate]

    - by Francis Goris
    This question already has an answer here: Reference: mod_rewrite, URL rewriting and “pretty links” explained 2 answers I have url like this: www.site.com/index.php?/genero/aventura/av/ But I would like this to be my new url: site.com/genero/aventura/av/ I used the following code: <IfModule mod_rewrite.c>RewriteEngine On RewriteCond %{HTTP_HOST} !^www.site.com/$ [NC] RewriteRule ^index.php\?/(.*)$ site.com/$1 [R=301,L] </IfModule> but only returns me: site.com/index.php?/genero/aventura/av/ This is my latest & full version: RewriteEngine on #RewriteCond $1 !^(index\.php|ver_capitulo\.html|google3436eb8eea8b8d6e\.html|BingSiteAuth\.xml |portadas|public|mp3|css|favicon\.ico|js|plantilla|i|swf|plugins|player\.swf|robots\.txt) RewriteCond $1 !^(index\.php|public|css|js|i|feed|portadas|robots\.txt|BingSiteAuth\.xml|plugins|i|mp3|favicon\.ico|pluginslist\.xml|google3436eb8eea8b8d6e\.html) RewriteRule ^(.*)$ /index.php?/$1 [L] #DirectoryIndex index.php #RewriteCond %{THE_REQUEST} http://www.page.com/index\.php [NC] #RewriteRule ^(.*?)index\.php$ http://page.com/$1 [L,R=301,NC,NE] #DirectoryIndex index.php #RewriteEngine On Thanks for reading.

    Read the article

  • How to user unloadStyleDeclarations?

    - by user300675
    I have a flex4 applciation (mx+spark). When I use: FlexGlobals.topLevelApplication.styleManager.loadStyleDeclarations(skinName, true); This works fine: new style is applied. The trouble is when I apply a new style, it mixes both: this happens because I need to Unload style first. I try to unload it with: FlexGlobals.topLevelApplication.styleManager.unloadStyleDeclarations("style/normal.swf",false); And I always got an error: ReferenceError: Error #1069: La property 0 cannot be found on Number and there is no default value. at normal/unloadOverrides()[null/normal-generated.as:721] at normal/unload()[null/normal-generated.as:676] Any idea on how to load/unload swf css in Flex4?

    Read the article

  • Can ANYONE get _lockroot to work?

    - by webfac
    Hi Guys, I have the following code which ultimately loads a SWF into movieclip 'myloader' using a movie clip loader, code as follows: var myload:MovieClipLoader = new MovieClipLoader(); var listener:Object = new Object(); myload.addListener(listener); listener.onLoadStart = function(){ animcontainer.myloader._lockroot = true; trace("Started"); } listener.onLoadInit = function(){ animcontainer.myloader._lockroot = true; trace("finished and locked"); } listener.onLoadComplete = function(){ animcontainer.myloader._lockroot = true; } myload.loadClip(path, animcontainer.myloader); The swf I am loading has pause, rewind and play buttons that must be referencing _root as they work fine when played alone. Upon loading them into myloader they no longer work. Based on the above code surely the myloader clip should be locking as _root after the load is complete? I have Googled myself dry on this one, no luck. ANY help will be much appreciated, Thanks.

    Read the article

  • How to split the chance to display SWFs evenly among banner collection?

    - by Michael Mao
    Hi all: I am working on The ausdcf.org to try adding several banner ads in swf format to the top. Everything starts to work, but I've got several questions that need your help: The client chose not to go with Google AdManager, but prefer a "minimal approach" to do this task. What I am trying to do is sort of "mimicking" the way Google AdManager does for banners, that is, to split the chance of each particular swf to be shown to the visitor evenly among the banner collection. Definitely I can add some jQuery code to do this from client-side, a random number generator and if-else statement would work - just $.load() it! However, what if I'd like to make sure those disabled Javascript (is there any now btw?) still be able to see different swfs in each visit. Any suggestion on how to approach this? Many thanks in advance.

    Read the article

  • Is it possible to make this Flex/Flash application safe?

    - by Frank
    I'm back with another Flex/Flash security question. I've already received some help from the community on this topic, but I'm still not quite sure this is the best way to do. Here's the thing. A flex web app, a lot of users (1000+), custom configuration of the application depending of the user group. Can I make this thing safe... or safer. For the moment, when a user comes to the application, there is only one configuration possible, but for the next version we've implented a multi-configuration protocol, this way : 1. The user connect to Default.aspx, server code process the windows credentials (whe are on intranet) and give the correct xml configuration file. 2. The flex app loads with the xml conf file as a flashvar and then the app 'builds' itself with the content of the xml file. As we know, since this is a flex application the swf is downloaded on the client computer and the xml file too. If more than one user connects to the app, from the same computer, the can possibly see the other xml file in the windows temp folder. The current directory of the application looks that way : Web site |-> default.aspx |-> index.swf |-> configAdmin.xml |-> configUserType1.xml |-> configUserType2.xml |-> com |-> a lot of swf and xml files I was first thinking making another directory (without read access for the client) containing all the configurations xml files, picking the right one, copying it to the client and deleting it afterwards. But it seems like I must let know the user know when downloading/deleting content on it's computer... I'm running out of ideas, so I hope you have some great ones. It's there are some design flaws (in the way the app is build, not in Flash :p) please share. I'm always looking forward to improve. Thanks Update : In browser Flash/Flex (without AIR that is) doesn't allow deleting file localy silently (on the client computer, where the application is). It's also not yet possible to get session data.

    Read the article

  • How do I get artifacts from one Maven module included in the resources of another in my build?

    - by Hanno Fietz
    I have Maven modules that produce a Flex application as an SWF file. I want to include that file in a web application that is made with another Maven module from the same build. I'm wondering how and at which lifecycle phase I get Maven to grab the artifact from the other module and put it insode the appropriate folder of the webapp module. Would I use a separate assembly module? The web app is running on a Jetty server in an OSGi environment (using Pax), the server side of the web app uses Struts. The final artifact as I see it would be a WAR file including my Action etc classes, JSP templates, static contents such as CSS or JS, and the SWF movies. I might be better off with these split over some other setup, but right now, I wouldn't know which.

    Read the article

  • Server Error in '/' Application.

    - by Surya sasidhar
    hi, in my application when i click on one of my button in the page it is giving error like this.. Could not find a part of the path 'V:\User\EnterTrailorVideos\luck.swf'. Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. Exception Details: System.IO.DirectoryNotFoundException: Could not find a part of the path 'V:\User\EnterTrailorVideos\luck.swf'. There is No folder ("EnterTrailorVideos") in my project. But it is showing like this can you help me

    Read the article

  • FLV Player Skin Custom URL

    - by Chris
    I have a flash banner ad (AS3) which uses a FLV Player component for a remove video. The Skin exports it's own SWF file for user with the video controls as I'm sure anyone familiar with Flash knows. Is there anyway to specify where this file is remotely? I have to provide 1 file to my advertiser, and do not want to have to create custom video controls for this. Is it possible to upload this swf file to a remote location and tell Flash to pull it from there? Any help would be greatly appreciated.

    Read the article

  • youtube video will not display in desktop Chrome

    - by mwalrath
    Youtube video does not show up in a modal window when viewed in a desktop version of Chrome. The modal window pops up but the youtube video does not. https://animalhealth.pfizer.com/sites/pahweb/US/EN/Products/Pages/ClarifideStories.aspx It works in IE and Firefox on Windows7, works in Chrome on Android ICS and iOS6 iPad. It is on a sharepoint site but if I open a version saved to my desktop it works fine in chrome. I am using jquery fancybox How it is called <a class="iframe" href="http://www.youtube.com/watch? v=nGAyZSFDYh0&feature=player_embedded#at=41" style=" float: left;"> javascript <script type="text/javascript"> $(".iframe").click(function() { $.fancybox({ 'padding' : 0, 'autoScale' : false, 'transitionIn' : 'none', 'transitionOut' : 'none', 'title' : this.title, 'width' : 680, 'height' : 495, 'href' : this.href.replace(new RegExp("watch\\?v=", "i"), 'v/'), 'type' : 'swf', 'swf' : { 'wmode' : 'transparent', 'allowfullscreen' : 'true' } }); return false; }); </script>

    Read the article

  • Adobe Flash not working in 12.04

    - by catnthehat
    I cannot get Adobe Flash working in either Firefox or Chrome. I have tried the Flash-Aid plug in for Firefox but it has not made any difference. As far as I can see, Flash installs without error and Firefox thinks it can run Flash but (for example) YouTube just shows a blank square where the movie should be me. Chrome reports "missing plugin". about:plugins in Firefox reports: Shockwave Flash File: libflashplayer.so Version: Shockwave Flash 11.2 r202 MIME Type Description Suffixes application/x-shockwave-flash Shockwave Flash swf application/futuresplash FutureSplash Player spl

    Read the article

  • How can I respond to mouse events in AS3?

    - by Gabriel Meono
    Background: Trying to make a simple "drop the ball" game. The code is located inside the first frame of the timeline. Nothing more is on the stage. Issue: Using QuickBox2D I made a simple If statement that drops and object acording the Mouse-x position: if (MouseEvent.CLICK) { sim.addCircle({x:mouseX, y:1, radius:0.25, density:5}); I imported the MouseEvent library: import flash.events.MouseEvent; Nothing happens if I click, no output errors either. See it in action: http://gabrielmeono.com/download/Lucky_Hit_Alpha.swf http://gabrielmeono.com/download/Lucky_Hit_Alpha.fla Full Code: [SWF(width = 350, height = 600, frameRate = 60)] import com.actionsnippet.qbox.*; import flash.events.MouseEvent; var sim:QuickBox2D = new QuickBox2D(this); sim.createStageWalls(); //var ball:sim.addCircle({x:mouseX, y:1, radius:0.25, density:5}); // // make a heavy circle sim.addCircle({x:3, y:1, radius:0.25, density:5}); sim.addCircle({x:2, y:1, radius:0.25, density:5}); sim.addCircle({x:4, y:1, radius:0.25, density:5}); sim.addCircle({x:5, y:1, radius:0.25, density:5}); sim.addCircle({x:6, y:1, radius:0.25, density:5}); // create a few platforms sim.addBox({x:3, y:2, width:4, height:0.2, density:0, angle:0.1}); // make 26 dominoes for (var i:int = 0; i<7; i++){ //End sim.addCircle({x:1 + i * 1.5, y:16, radius:0.1, density:0}); sim.addCircle({x:2 + i * 1.5, y:15, radius:0.1, density:0}); //Mid end sim.addCircle({x:0 + i * 2, y:14, radius:0.1, density:0}); sim.addCircle({x:0 + i * 2, y:13, radius:0.1, density:0}); sim.addCircle({x:0 + i * 2, y:12, radius:0.1, density:0}); sim.addCircle({x:0 + i * 2, y:11, radius:0.1, density:0}); sim.addCircle({x:0 + i * 2, y:10, radius:0.1, density:0}); //Middle Start sim.addCircle({x:0 + i * 1.5, y:09, radius:0.1, density:0}); sim.addCircle({x:1 + i * 1.5, y:08, radius:0.1, density:0}); sim.addCircle({x:0 + i * 1.5, y:07, radius:0.1, density:0}); sim.addCircle({x:1 + i * 1.5, y:06, radius:0.1, density:0}); } if (MouseEvent.CLICK) { sim.addCircle({x:mouseX, y:1, radius:0.25, density:5}); sim.start(); /*sim.mouseDrag();*/ }

    Read the article

  • BOX2D and AS3: Mouse Event not working

    - by Gabriel Meono
    Background: Trying to make a simple "drop the ball" game. The code is located inside the first frame of the timeline. Nothing more is on the stage. Issue: Using QuickBox2D I made a simple If statement that drops and object acording the Mouse-x position: if (MouseEvent.CLICK) { sim.addCircle({x:mouseX, y:1, radius:0.25, density:5}); I imported the MouseEvent library: import flash.events.MouseEvent; Nothing happens if I click, no output errors either. See it in action: http://gabrielmeono.com/download/Lucky_Hit_Alpha.swf http://gabrielmeono.com/download/Lucky_Hit_Alpha.fla Full Code: [SWF(width = 350, height = 600, frameRate = 60)] import com.actionsnippet.qbox.*; import flash.events.MouseEvent; var sim:QuickBox2D = new QuickBox2D(this); sim.createStageWalls(); //var ball:sim.addCircle({x:mouseX, y:1, radius:0.25, density:5}); // // make a heavy circle sim.addCircle({x:3, y:1, radius:0.25, density:5}); sim.addCircle({x:2, y:1, radius:0.25, density:5}); sim.addCircle({x:4, y:1, radius:0.25, density:5}); sim.addCircle({x:5, y:1, radius:0.25, density:5}); sim.addCircle({x:6, y:1, radius:0.25, density:5}); // create a few platforms sim.addBox({x:3, y:2, width:4, height:0.2, density:0, angle:0.1}); // make 26 dominoes for (var i:int = 0; i<7; i++){ //End sim.addCircle({x:1 + i * 1.5, y:16, radius:0.1, density:0}); sim.addCircle({x:2 + i * 1.5, y:15, radius:0.1, density:0}); //Mid end sim.addCircle({x:0 + i * 2, y:14, radius:0.1, density:0}); sim.addCircle({x:0 + i * 2, y:13, radius:0.1, density:0}); sim.addCircle({x:0 + i * 2, y:12, radius:0.1, density:0}); sim.addCircle({x:0 + i * 2, y:11, radius:0.1, density:0}); sim.addCircle({x:0 + i * 2, y:10, radius:0.1, density:0}); //Middle Start sim.addCircle({x:0 + i * 1.5, y:09, radius:0.1, density:0}); sim.addCircle({x:1 + i * 1.5, y:08, radius:0.1, density:0}); sim.addCircle({x:0 + i * 1.5, y:07, radius:0.1, density:0}); sim.addCircle({x:1 + i * 1.5, y:06, radius:0.1, density:0}); } if (MouseEvent.CLICK) { sim.addCircle({x:mouseX, y:1, radius:0.25, density:5}); sim.start(); /*sim.mouseDrag();*/ }

    Read the article

  • How to detect collisions in AS3?

    - by Gabriel Meono
    I'm trying to make a simple game, when the ball falls into certain block, you win. Mechanics: The ball falls through several obstacles, in the end there are two blocks, if the ball touches the left block you win, the next level will contain more blocks and less space between them. Test the movie (click on the screen to drop the ball): http://gabrielmeono.com/downloads/Lucky_Hit_Alpha.swf These are the main variables: var winBox:QuickObject;//You win var looseBox:QuickObject;//You loose var gameBall:QuickObject;//Ball dropped Question: How do I trigger a collision function if the ball hits the winBox? (Win message/Next level) Thanks, here is the full code: package { import flash.display.MovieClip; import com.actionsnippet.qbox.*; import flash.events.MouseEvent; [SWF(width = 600, height = 600, frameRate = 60)] public class LuckyHit extends MovieClip { public var sim:QuickBox2D; var winBox:QuickObject; var looseBox:QuickObject; var gameBall:QuickObject; /** * Constructor */ public function LuckyHit() { sim = new QuickBox2D(this); //sim.createStageWalls(); winBox = sim.addBox({x:5,y:600/30, width:300/30, height:10/30, density:0}); looseBox = sim.addBox({x:15,y:600/30, width:300/30, height:10/30, density:0}); // make obstacles for (var i:int = 0; i<(stage.stageWidth/50); i++){ //End sim.addCircle({x:1 + i * 1.5, y:16, radius:0.1, density:0}); sim.addCircle({x:2 + i * 1.5, y:15, radius:0.1, density:0}); //Mid End sim.addCircle({x:0 + i * 2, y:14, radius:0.1, density:0}); sim.addCircle({x:0 + i * 2, y:13, radius:0.1, density:0}); sim.addCircle({x:0 + i * 2, y:12, radius:0.1, density:0}); sim.addCircle({x:0 + i * 2, y:11, radius:0.1, density:0}); sim.addCircle({x:0 + i * 2, y:10, radius:0.1, density:0}); //Middle Start sim.addCircle({x:0 + i * 1.5, y:09, radius:0.1, density:0}); sim.addCircle({x:1 + i * 1.5, y:08, radius:0.1, density:0}); sim.addCircle({x:0 + i * 1.5, y:07, radius:0.1, density:0}); sim.addCircle({x:1 + i * 1.5, y:06, radius:0.1, density:0}); } sim.start(); stage.addEventListener(MouseEvent.CLICK, _clicked); } /** * .. * @param e MouseEvent.CLICK */ private function _clicked(e:MouseEvent) { gameBall = sim.addCircle({x:(mouseX/30), y:(1), radius:0.25, density:5}); } } }

    Read the article

  • Reading A User's Profile

    - by Ricardo Peres
    One frequent question is: how can we read a user's profile properties? The answer is simple, we use class ProfileBase: //a specific user ProfileBase profile = ProfileBase.Create("username", true); //all users BaseProfile [] profiles = Membership.GetAllUsers().Cast().Select(u = ProfileBase.Create(u.UserName, true)).ToArray(); SyntaxHighlighter.config.clipboardSwf = 'http://alexgorbatchev.com/pub/sh/2.0.320/scripts/clipboard.swf'; SyntaxHighlighter.brushes.CSharp.aliases = ['c#', 'c-sharp', 'csharp']; SyntaxHighlighter.all();

    Read the article

  • Creating an XML / Flash Slideshow with Captions

    This article guides about to create an XML / Flash slideshow with improved reusability and content updatability. It creates an information bridge between Flash .SWF file and Images Source through XML....Did you know that DotNetSlackers also publishes .net articles written by top known .net Authors? We already have over 80 articles in several categories including Silverlight. Take a look: here.

    Read the article

  • Is there a jQuery lightbox plugin that has thumbnails inside the box?

    - by Gabriel
    I'm trying to find a lightbox style plugin in jQuery that displays thumbnails at the bottom of the picture (or video, or whatever). I found plenty of lightbox plugins, but none that allows navigation by thumbnail inside the box. The plugin must be able to open images, swf and inline content. I realize that jQuery will not be able to generate the thumbnails and that's ok. Do you have any good ones to suggest? Thanks

    Read the article

  • Creating an XML / Flash Slideshow with Captions

    This article guides about to create a Flash Slideshow using XML. Usually, when we create a slideshow in flash, all the images get integrated into the movie itself, doing this slashes the reusability of the movie file (swf) and updatability of the movie content. Here I created an information bridge b

    Read the article

  • How config nginx to serve flv video streaming with JWplayer

    - by Nisanio
    I need to serve flv files from one server, and show those videos on a web page located in another server, with JWPlayer. I already config nginx with the flv module, an put this on nginx.conf location ~ \.flv$ { flv; } The code I use in the jwplayer is <object id="player" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" name="player" width="328" height="200"> <param name="movie" value="player.swf" /> <param name="allowfullscreen" value="true" /> <param name="allowscriptaccess" value="always" /> <param name="flashvars" value="file=http://XX.XX.XX.XX/vid5.flv&image=preview2.jpg" /> <embed type="application/x-shockwave-flash" id="player2" name="player2" src="player.swf" width="630" height="385" allowscriptaccess="always" allowfullscreen="true" flashvars="file=http://XX.XX.XX.XX/vid5.flv&image=preview2.jpg" /> </object> Where XX.XX.XX.XX is the ip address of the server (we'll config an appropiate domain, but first i have to make the whole thing works :) ) The problem is that nothing happen. I don't know what to do next, all the articles on the internet only talks about how compile the flv module (already done) and add the nginx.conf lines. Any help would be greatly appreciate Thanks in advance

    Read the article

  • redirect from mysite.com to www.mysite.com

    - by jml
    hi there, i know that this has been answered many many times, so if someone wants to point me to another thread that answers my question specifically, that is fine... for right now, my searches aren't yielding many results. so i have a website like mysite.com that has a flash swf embedded in it and i go to www.mysite.com ... all of the sudden, things don't work properly. i would like to get to the bottom of this, because it's not like the page just "doesn't load" at all; it loads and i can only do certain things; as if certain functionality is disabled (might be url requests for specific urls etc). do i need to manage this in my control panel? i wouldn't assume so, because the site loads; just has a crippled functionality from within the swf. i was thinking it might have more to do with my crossdomain.xml file; could this be the case? thanks for any tips or suggestions.

    Read the article

  • How to get nginx to pass HTTP_AUTHORIZATION header to Apache

    - by codeinthehole
    Am using Nginx as a reverse proxy to an Apache server that uses HTTP Auth. For some reason, I can't get the HTTP_AUTHORIZATION header through to Apache, it seems to get filtered out by Nginx. Hence, no requests can authenticate. Note that the Basic auth is dynamic so I don't want to hard-code it in my nginx config. My nginx config is: server { listen 80; server_name example.co.uk ; access_log /var/log/nginx/access.cdk-dev.tangentlabs.co.uk.log; gzip on; proxy_set_header Host $host; proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; proxy_read_timeout 120; location / { proxy_pass http://localhost:81/; } location ~* \.(jpg|png|gif|jpeg|js|css|mp3|wav|swf|mov|doc|xls|ppt|docx|pptx|xlsx|swf)$ { if (!-f $request_filename) { break; proxy_pass http://localhost:81; } root /var/www/example; } } Anyone know why this is happening? Update - turns out the problem was something I had overlooked in my original question: mod_wsgi. The site in question here is a Django site, and it turns out that Apache does get the auth variables passed through, however mod_wsgi filters them out. The resolution is to use: WSGIPassAuthorization On See http://www.arnebrodowski.de/blog/508-Django,-mod_wsgi-and-HTTP-Authentication.html for more details

    Read the article

  • What is the best hosting option for Flash web-widget?

    - by par
    Our Flash web-widget has got highly popular. It is downloaded around 100,000 times per day. And that is the problem. Our server bandwidth is too narrow to deliver the widget to the clients fast. The widget is loaded very slow. Probably 20 times slower than before (at peak times). Probably I have choosen not the right hoster for my task - delivering 1 MB Flash widget to 100,000 users per day. What is the best hosting solution in my case? I'm not good at server administration so forgive me if I sound naive. The details are the following. Our hoster options: -Dedicated server, Ubuntu -10 Mbit Connection -monthly bandwidth limit: 2000 GB Widget size is 1 MB. The widget consists of the main SWF and a number of loaded SWF and data files. This is a part of Apache Status report taken right now ---- Server uptime: 1 hour 2 minutes 38 seconds Total accesses: 74865 - Total Traffic: 5.8 GB CPU Usage: u28 s7.78 cu0 cs0 - .952% CPU load 19.9 requests/sec - 1.6 MB/second - 81.1 kB/request 200 requests currently being processed, 0 idle workers WWWWWWWWWWWWWWWWWWWWWWWWCWWWWWWWWWWWWWWWWWWWWWWWWWWCWWWWWWWCWWWW WWWWWCWWWWWWWWWWWWWWCWWWWWWWWWWWWCWWWWWWWWCWWCWWWWWWWWWWWWWWWWWW WWWWWWWWWWWWWWWWCWWWWWWWWWWWWWWWWWWWWWWWWWWWCWCWWWWWWWWWWWWWWWCW WWWWWWWW........................................................ ----

    Read the article

  • Reflector – The King is Dead. Long Live the King.

    - by Sean Feldman
    There was enough of responses for Red Gate announcement about free version of .NET Reflector. Neither there’s a need to explain how useful the tool is for almost any .NET developer. There were a lot of talks about the price – $35 is it something to make noise about or just accept it and move on. Honestly, I couldn’t make my mind and was sitting on a fence. Today I learned some really exciting news – two (not one), two different initiatives to replace Reflector. A completely free ILSpy from SharpDevelop Commercial later to be stand-alone free decompiler tool from JetBrains These are great news. First – ILSpy is already doing what I need – you can download it and start using. Having experience with a few projects from SharpDevelop I believe it will be a great tool to have. One of immediate things that I found is reflecting obfuscated assemblies. Reflector blows up and closes, where ILSpy takes it gracefully and just shows an exception with no additional popup windows. JetBrains – company I highly respect. This is the case where I would continue paying money for their product and get more productivity. I am heavily relying on R# to do my job, and having a reflecting option would only add oil into fire of convincing others to use the tool. Though what I was excited was the statement JetBrains boldly put out: …it’s going to be released this year, and it’s going to be free of charge. And by saying “free”, we actually mean “free”.

    Read the article

  • Functions registered with ExternalInterface.addCallback not available in Javascript

    - by Selene
    I'm working on a Flash game that needs to call some Javascript on the page and get data back from it. Calling Javascript from Flash works. Calling the Flash functions from Javascript (often) doesn't. I'm using the Gaia framework. What happens: The swf is loaded in with SWFObject There's a button in the Flash file. On click, it uses ExternalInterface.call() to call a Javascript function. This works. The Javascript function calls a Flash function that was exposed with ExternalInterface.addCallback(). Sometimes, the Javascript produces the following error: TypeError: myFlash.testCallback is not a function. When the error happens, it affects all functions registered with addCallback(). Gaia and some of its included libraries use addCallback(), and calling those functions from Javascript also produces the TypeError. Waiting a long time before pressing the button in Flash doesn't solve the error. Having Flash re-try addCallback() periodically doesn't solve the error When the error occurs, ExternalInterface.available = true and ExternalInterface.objectID contains the correct name for the Flash embed object. When the error occurs, document.getElementById('myflashcontent') correctly returns the Flash embed object. From my Page class: public class MyPage extends AbstractPage { // declarations of stage instances and class variables // other functions override public function transitionIn():void { send_button.addEventListener(MouseEvent.MOUSE_UP, callJS); exposeCallbacks(); super.transitionIn(); } private function exposeCallbacks():void { trace("exposeCallbacks()"); if (ExternalInterface.available) { trace("ExternalInterface.objectID: " + ExternalInterface.objectID); try { ExternalInterface.addCallback("testCallback", simpleTestCallback); trace("called ExternalInterface.addCallback"); } catch (error:SecurityError) { trace("A SecurityError occurred: " + error.message + "\n"); } catch (error:Error) { trace("An Error occurred: " + error.message + "\n"); } } else { trace("exposeCallbacks() - ExternalInterface not available"); } } private function simpleTestCallback(str:String):void { trace("simpleTestCallback(str=\"" + str + "\")"); } private function callJS(e:Event):void { if (ExternalInterface.available) { ExternalInterface.call("sendTest", "name", "url"); } else { trace("callJS() - ExternalInterface not available"); } } } My Javascript: function sendTest(text, url) { var myFlash = document.getElementById("myflashcontent"); var callbackStatus = ""; callbackStatus += '\nmyFlash[testCallback]: ' + myFlash['testCallback']; //console.log(callbackStatus); var errors = false; try { myFlash.testCallback("test string"); } catch (err) { alert("Error: " + err.toString()); error = true; } if (!error) { alert("Success"); } } var params = { quality: "high", scale: "noscale", wmode: "transparent", allowscriptaccess: "always", bgcolor: "#000000" }; var flashVars = { siteXML: "xml/site.xml" }; var attributes = { id: "myflashcontent", name: "myflashcontent" }; // load the flash movie. swfobject.embedSWF("http://myurl.com/main.swf?v2", "myflashcontent", "728", "676", "10.0.0", serverRoot + "expressInstall.swf", flashVars, params, attributes, function(returnObj) { console.log('Returned ' + returnObj.success); if (returnObj.success) { returnObj.ref.focus(); } });

    Read the article

  • FusionCharts Sharepoint And dataUrl param.

    - by oivoodoo
    Hi, everyone. I have problem with fusioncharts evaluation in the ASP .NET(Sharepoint Portal). I am customizing survey list for providing new view. I added to scheme.xml the next code. <View BaseViewID="4" Type="HTML" WebPartZoneID="Main" DefaultView="TRUE" DisplayName="Charts" SetupPath="pages\viewpage.aspx" ImageUrl="/_layouts/images/survey.png" Url="overview.aspx" FreeForm="TRUE" ReadOnly="TRUE"> <!-- _locID@DisplayName="camlidV1" _locComment=" " --> <Toolbar Type="Standard" /> <ViewFields> </ViewFields> <ViewEmpty> <SetVar Name="HandlerUrl">/_layouts/IEFS/SurveyHandler.aspx</SetVar> <HTML> <![CDATA[ <!-- START Code Block for Chart 'ChartName' --> <object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0" width="350" height="350" name="SurveyChart"> <param name="allowScriptAccess" value="always" /> <param name="movie" value="/_layouts/IEFS/FusionCharts/MSCombi3D.swf"/> <param name="FlashVars" value="&chartWidth=350&chartHeight=350&debugMode=1&dataURL=]]> </HTML> <GetVar Name="HandlerUrl" /> <HTML> <![CDATA["/>]]> </HTML> <HTML> <![CDATA[ <param name="quality" value="high" /> <embed src="/_layouts/IEFS/FusionCharts/MSCombi3D.swf" FlashVars="&chartWidth=350&chartHeight=350&debugMode=1&dataURL=]]> </HTML> <GetVar Name="HandlerUrl" /> <HTML> <![CDATA[" quality="high" width="350" height="350" name="ChartName" allowScriptAccess="always" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" /> </object> <!-- END Code Block for Chart 'ChartName' --> ]]> </HTML> </ViewEmpty> As you can see I've just create standard object tag of fusioncharts control(I got it from examples). But when page is rendered I can see the next following error: And I have error: INFO: XML Data provided using dataURL method. dataURL provided: ./_layouts/IEFS/SurveyHandler.aspx dataURL invoked: ./_layouts/IEFS/SurveyHandler.aspx?FCTime=223 ERROR: An error occurred while loading data. Please check your dataURL, by clicking on the "dataURL invoked" link above, to see if it's returing valid XML data. Common causes for error are: No URL Encoding provided for querystrings in dataURL. If your dataURL contains querystrings as parameters, you'll need to URL Encode the same. e.g., Data.asp?id=101&subId=242 should be Data%2Easp%3Fid%3D101%26subId%3D242 Different sub-domain of chart .swf and dataURL. Both need to be same owing to sandbox security. Network error My data-page(handler) is rendered valid xml data. I read this link http://www.fusioncharts.com/docs?/Debug/Basic.html, but it doesn't help me. Have ever you seen same error before? With The Best Regards, Alexander.

    Read the article

< Previous Page | 20 21 22 23 24 25 26 27 28 29 30 31  | Next Page >