Javascript Play() function

Hello,
I've found a couple examples of it working via google. However I can't seem to get it working for my flash video. Is this function no longer available in later versions of flash? Is there another way to do it without using actionscript? I'm just trying to start my flash video through javascript. Thanks for any help.

Hi,
You can try:
function checkCar() {
if (AdobeEdge.countCar == 5){
var iCall = AdobeEdge.getComposition("EDGE-172492634").getStage();
      iCall.$("cart").removeClass( "hidden" );
      iCall.getSymbol("cart").play();

Similar Messages

  • How to call Edge Animate's play function from external javascript

    I have a symbol on the stage called "cart".... inside the symbol is my graphic that has a motion path put on it to the timeline (it is called "car_v1").
    On my stage I have a code to hide the symbol cart with an external css class :
    sym.$("cart").addClass( "hidden" );  ( this is the css - .hidden { display: none; } )
    I have a function that calls an external javascript file.. from that external file I want to get the timeline animation to work:
    here is the function called:
    checkCar();
    and here is the function:
    function checkCar() {
    if (AdobeEdge.countCar == 5){
    AdobeEdge.getComposition("EDGE-172492634").getStage().$("cart").removeClass( "hidden" ); // this works!
    AdobeEdge.getComposition("EDGE-172492634").getStage().$("cart").play(); //doesn't work!        <------------this is the line I need help with!
    // sym.getSymbol("cart").play(); // this works inside of edge and the timeline animation runs!!!
    Can anyone help me get the play function to work from my external javascript file? Thanks!
    Kristen

    Hi,
    You can try:
    function checkCar() {
    if (AdobeEdge.countCar == 5){
    var iCall = AdobeEdge.getComposition("EDGE-172492634").getStage();
          iCall.$("cart").removeClass( "hidden" );
          iCall.getSymbol("cart").play();

  • JavaScript Alert functionality in PL/SQL

    I'm in need of implementing the JavaScript "Alert" functionality (display message and wait for user to acknowledge) in the "before displaying the page" PL/SQL block of portal reports and forms. While I'm at it - How about the JavaScript "history.back" function as well?
    Is this possible? Can you point me in the right direction.

    Hi,
    Where Portal says "before displaying the page" what it means is that it will run this code before it starts to htp.p() out the HTML of the page.
    In WebDB this was actually what happened, in Portal there are some elements of HTML output BEFORE this block of code is run.
    Anyway I don't think that you can have an alert that displays before the page is loaded. The page will still show behind the alert.
    To get around this you would need a blank page to show your alert that forwards you on to the required page.
    The history function can be called by the onclick event of a button or you can access Javascript through an anchor tag:-
    link text
    Regards Michael

  • Javascript sort() function not working correctly

    I have an image gallery that automatically loads via a PHP readdir function which populates an array, and then I have a Javascript sort() function which sorts the images in order numerically. In Chrome and Safari, the images display as numbered in the directory. However, in Firefox and Internet Explorer, they display out of order (firefox) and not at all (ie). Here is the code for the php file: <?
    Header("content-type: application/x-javascript");
    function returnimages($dirname=".") {
    $pattern="(\.jpg$)|(\.png$)|(\.jpeg$)|(\.gif$)";
    $files = array();
    $curimage=0;
    if($handle = opendir($dirname)) {
    while(false !== ($file = readdir($handle))){
    $file = basename($file,".jpg");
    echo 'myImg['.$curimage.']="'.$file .'";';
    $curimage++;
    closedir($handle);
    return($files);
    echo 'var myImg=new Array();';
    returnimages()
    ?>
    and here is the code for the javascript sort:
    function sortNumber(a,b)
    return a - b;
    myImg.sort(sortNumber);
    // Tell browser the type of file
    myImgEnd = ".jpg";
    var i = 0;
    // Create function to load image
    function loadImg(){
    document.imgSrc.src = myImg[i] + myImgEnd;
    Any ideas as to why Firefox is behaving this way?

    After you check the box to sort on the column, are you making sure to select a sort order for the same column?
    Earl

  • How can I decode Japanese character using java from JavaScript escape() function

    Hi:
    I have an application which supports Japanese character. I am using JavaScript escape() function to encode the text field before I posted it through web server and then I will just convert it into hex number to decode it through an Integer. It works fine for the character between ascii 1-255. However, it faild on all the double bytes character. All the unicode has the format of "%uXXXX" after it is escaped from JavaScript. How can I resolve the decoding problem?
    Thank,
    David

    Please use 'encodeURI()', though it is supported only IE after 5.5.
    I'm not sure Netscape.
    Thanks,
    Katsumi
    dwang <[email protected]> wrote:
    Hi:
    I have an application which supports Japanese character. I am using JavaScript
    escape() function to encode the text field before I posted it through
    web server and then I will just convert it into hex number to decode
    it through an Integer. It works fine for the character between ascii
    1-255. However, it faild on all the double bytes character. All the
    unicode has the format of "%uXXXX" after it is escaped from JavaScript.
    How can I resolve the decoding problem?
    Thank,
    David

  • IPOD Touch music playing functions

    Seems like Apple has cut down on the music playing functions on the iPOD Touch. I cannot have my Touch to shuffle by albums. And when I stop listening to a song, it won't pick up to where I left when I start listening again. So I have to remember which album I was listening and to which song I was. These are simple functions that were left out on the Touch and it's kind of a bummer. I hope this will be corrected on a future update. All the other applications are very cool, but let's not forget that the primary use for an iPOD is to play music.

    Does the iPod still charge and syn with the computer?
    Try the stamdard fixes:
    - Reset. Nothing will be lost.
    Reset iPod touch:  Hold down the On/Off button and the Home button at the same time for at
    least ten seconds, until the Apple logo appears.
    - Restore from backup
    - Restore to factory defaults/new iPod.

  • Plays Function - How to restore the totals that i used to get lisetd on my old PC?

    Any help on how to restore the "Plays" function would be gratefully received!  I have recently installed itunes on a new PC and this function does not seem to work in the Library section.

    Perhaps you need to revist the way you moved your library. This migrate iTunes library post shows ways to do it that bring over all the data intact. If that is no longer possible see my script SyncStats.
    tt2

  • Javascript escape() function

    Hello everyone,
    I have a select input in a form, some of the options have strings in which there is
    a space. like "San Francisco", "Los Angelos". I know javascript escape function can transform
    those strings to URL string like, "San%20Francisco". But i tried several times with no luck:
    Here is my code:<select name="city">
      <option value=escape('<%= cityName%>') selected> <%= cityName%>
    </select> The value it submitted to server is not what I expected, it submit the whole thing:
    escape("San Francisco").
    Does anyone know what is the right way to invoke escape function in this circumstance?
    Thank you in advance !
    Rachel

    Hmm.. it should be the same for GET or POST. The javascript encode function doesn't work the way you were using it. It would work if you did something like this:
    <script>document.write('<option value="<%=city%>"><%=city%></option>');</script>
    But the problem with this is you need to make the user aware that they need to have JavaScript enabled. So better to encode in Java before writing with URLEncoder, like you said.
    But I'm pretty sure GET or POST shouldn't be different for that type of thing. Browser bug, maybe?

  • No resume play function in Netflix and other issues

    1. No "resume play" function in Netflix?
    2. Music playlists in alpha order only
    3. Netflix hangs on loading when trying to play second video in a row; have to go out completely
    4. Long list of music playlists takes 2-3 minutes to load; sometimes list flashes then disappears; when backtracking from song, complete list of playlists will not appear; keeps reverting to song selection
    5. Am able to play Netflix movie at 720p, unlike with my PS3

    PS. pardon the typos, i meant:
    So apparently everyone but me has a resume play button in netflix. how come i'm missing it, and how do i get it? please help!

  • How do I activate the "last played" function on my Touch 4G

    How do I Activate the "last played" function on my ipod touch 4G?

    I don't believe that there in a "Last played" function in the iPod Music player.
    There is a "Last played" stat which can be viewed (optionally via View / View Options... menu item) in iTunes on a computer.

  • Air-Play functionality on IOS 8

    Can you tell me, is it possible to revert from IOS 8.1.3 back to IOS 7 ?
    With IOS 7 it was possible to stream a movie on the iphone and play it through the apple TV. Once playing, you could then come out of the browser and leave it playing while you used other apps.
    The Air play functionality with IOS 8 is primitive in comparison ! Often, only the sound casts to the TV and if you do get the picture cast too, if you come out of the browser to read a text or such, it stops playing.
    Please tell me there is a way to revert to IOS 7 ?
    IOS 8 has ruined the Apple TV experience when used in conjunction with iphone!

    Thanks for your reply. Having already done a little digging, it appears I am not alone.
    With IOS 7, when you played a video in the browser there was a button in the bottom right window which gave you the option to play it on Apple TV. This button has now been removed and you must bring up the menu first. Select apple TV, then drop down the menu again. Seems like a step backwards having to perform a number of additional steps to perform the same function. Particularly when it appears to cause problems playing content.
    I am blaming IOS 8 as there were never any problems with IOS 7. Now there are numerous issues with it.
    Appreciate your input Lawrence. Thanks.

  • Play function disabled

    As soon I install the printer on Window 8, the play function from my CS6 audition become disabled? I try to reinstall the CS6, loaded all updates, remove the printer driver but still not working. Any ideas?

    The only thing that no play function means is that Audition is disconnected from the audio transport - ie, your sound device. So whatever you've done has caused a disconnection... and I doubt very much whether this has anything to do with a printer at all, unless you have a single USB port with both a printer and a sound device, and they're arguing.

  • How can I use JavaScript extention functions with Xalan for transforming XML with XSL

    While transforming standart XML and XSL files to HTML with this servlet:
    package mypackage1;
    import javax.servlet.*;
    import javax.servlet.http.*;
    import java.io.*;
    import java.util.*;
    import java.net.URL;
    import javax.xml.transform.*;
    import javax.xml.transform.stream.StreamSource;
    import javax.xml.transform.stream.StreamResult;
    import org.mozilla.javascript;
    public class Servlet2 extends HttpServlet
    private static final String CONTENT_TYPE = "text/html; charset=windows-1252";
    public void init(ServletConfig config) throws ServletException
    super.init(config);
    public void doGet(HttpServletRequest request, HttpServletResponse response)throws ServletException, IOException
    try
    response.setContentType(CONTENT_TYPE);
    PrintWriter out = response.getWriter();
    TransformerFactory tFactory = TransformerFactory.newInstance();
    Source xmlSource = new StreamSource(new FileReader("c:/aaa.xml"));
    Source xslSource = new StreamSource(new FileReader("c:/bbb.xsl"));
    Transformer transformer = tFactory.newTransformer(xslSource);
    transformer.transform (xmlSource, new StreamResult(out));
    catch (Exception e)
    e.printStackTrace();
    everything is going ok,
    but when try to use javascript function in XSL file, for example like in this:
    <?xml version="1.0"?>
    <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"
    xmlns:lxslt="http://xml.apache.org/xslt" xmlns:my-ext="ext1"
    extension-element-prefixes="my-ext">
    <lxslt:component prefix="my-ext"
    functions="getdate">
    <lxslt:script lang="javascript">
    function getdate() {
    var d = new Date();
    return d.toUTCString();
    </lxslt:script>
    </lxslt:component>
    <xsl:template match="/">
    <p><xsl:copy-of select="my-ext:getdate()"/></p>
    </xsl:template>
    </xsl:stylesheet>
    recieve error-message:
    XSL-1000: (Fatal Error) Error while parsing XSL file (Extension function namespace should start with 'http://www.oracle.com/XSL/Transform/java/'.).
    What kind of namespace I should specify?

    Hello, Paul.
    I'm sure you may not use JavaScript as a language for creating XSLT extention functions with Oracle XDK Parser. This is since parser might have JavaScript interpreter to work with JavaScript, but it has not.
    If you need to build any XSLT extention functions you must build them as Java class' static methods.
    After that, you define the usage of the class by mean of namespace declaration as:
    xmlns:your-ns="http://www.oracle.com/XSL/Transform/java/yourpackage.Yourclass"
    (Prefix "http://www.oracle.com/XSL/Transform/java/" may differs if you use non-Oracle XML parser)
    and use class' static method in XSLT:
    <xsl:value-of select="your-ns.staticMethodName(paramsIfAny)"/>
    In your case you may wish to use standard Date class:
    xmlns:date="http://www.oracle.com/XSL/Transform/java/java.util.Date"
    <xsl:value-of select="date:toString(date:new)"/>

  • Javascript is not working on some sites, and some sites also display in what looks like arabic. whats going on? how do i fix the javascript problem? javascript IS functioning in other browsers.

    Site displays fine in IE but in Mozilla, displays in text only, with the message: "Billboard requires a JavaScript enabled browser to get the full experience." Getting similar messages on other sites. Also, some sites are displaying in part English, part what looks like Arabic to me. Whats that about? Havent played with any language settings- in the browser OR on my computer. The affected sites listed are both displaying in text only. The login page for Mozilla website is one of the sites i mentioned displaying in part (Arabic?)

    Reload a web page and bypass the cache with:
    * Press and hold Shift and left-click the Reload button.
    * Press "Ctrl + F5" or press "Ctrl + Shift + R" (Windows,Linux)
    * Press "Cmd + Shift + R" (MAC)
    See [[Keyboard shortcuts]] and [[Mouse shortcuts]]
    * "Remove the Cookies" from sites that cause problems: Tools > Options > Privacy > Cookies: "Show Cookies"
    Start Firefox in [[Safe Mode]] to check if one of the add-ons is causing the problem (switch to the DEFAULT theme: Tools > Add-ons > Themes).
    * Don't make any changes on the Safe mode start window.
    See:
    * [[Troubleshooting extensions and themes]]
    * [[Troubleshooting plugins]]
    If it does work in Safe-mode then disable all extensions and then try to find which is causing it by enabling one at a time until the problem reappears.
    * Use "Disable all add-ons" on the [[Safe mode]] start window to disable all extensions.
    * Close and restart Firefox after each change via "File > Exit" (Mac: "Firefox > Quit"; Linux: "File > Quit")

  • Trouble with using javascript $s function to populate a page item

    Hello Oracle APEX Community,
    I'm working on a drilldown dashboard page and have been encountering a problem when i try to populate a Text Page Item (hidden or not) using the javascript built in $s function.
    The function works great when the data is a number such as dept_id (even if the field type is varchar). However, trying to pass anything which is a text the process fails, except when a value is hard-coded as a parameter for the function. So for example, I have a chart with counts of constituents by state. I would like to populate (filter) a table based on when you click on a bar for a state without having to submit the page. I'm using dynamic actions and a built in javascript function in the SQL for the chart to accomplish this; but again, it works great when I use a varchar field like the FIPS code (i.e. the FIPS for Texas is '48'), but when I try to populate the page item using the state abbreviation 'TX' (again varchar) it fails.
    Here's an example of code that works:
    SELECT 'javascript:$s("P1_DEPTNO",'||d.deptno||')' LINK,
    d.dname LABEL,
    sum(e.SAL) sal
    FROM emp e, dept d
    where e.deptno = d.deptno
    group by 'javascript:$s("P1_DEPTNO",'||d.deptno||')', d.dname And here's an example of code that does not work:
    SELECT 'javascript:$s("P1_DEPTNO",'||d.loc||')' LINK,
    d.dname LABEL,
    sum(e.SAL) sal
    FROM emp e, dept d
    where e.deptno = d.deptno
    group by 'javascript:$s("P1_DEPTNO",'||d.loc||')', d.dname However, when I hard code a text value the script works:
    SELECT 'javascript:$s("P1_DEPTNO","BOSTON")' LINK,
    d.dname LABEL,
    sum(e.SAL) sal
    FROM emp e, dept d
    where e.deptno = d.deptno
    group by 'javascript:$s("P1_DEPTNO","BOSTON")', d.dname
    ORDER BY d.dname I'm encountering this problem on several versions of APEX: (4.0.2.00.07-local installation) and (4.1.0.00.28-apex.oracle.com)
    Does anybody know of this problem and how to solve it? I've looked for settings on the page item itself, and can't figure it out.
    I've re-written my sql to utilize the value fields of my tables instead but I have some objects on the page which are really going to depend on the character based data instead.
    Thanks,
    Wayne

    In your javascript you are generating, surround your value with double-quotes and it'll should then always work with both numbers and strings (your strings are probably being interpreted as variable names and they don't exist at runtime, hence erroring out).
    Example:
    SELECT 'javascript:$s("P1_DEPTNO","'||d.loc||'")' LINK,Edited by: gti_matt on Aug 16, 2011 9:50 AM

Maybe you are looking for