Widget Code

Hi,
Where can i get those Widget Code for the HTML Snippet purpose?
Any recommendation?
e.g, i need a Form...there will show all those creative form which allow you to edit the content or title or email address summited to...and copy the embed code for iWeb
Thanks and appreciate!!

Hi Roddy,
At last,i did it.Thank you so much..really useful!!!
But i wish to Change some setting which is IT doesn't provide when building up the form.
I w'ld like to Change the Color of the Field and the Color of the Background as well...
what s'ld i do?

Similar Messages

  • How to: Embed YouTube in Ibook/Location of File, Open in Dashboard Widget Code?

    Hi,
    I am new to the whole Mac experience and loving it after 25 years locked into the MSGATES paradigm. I have been playing around with Ibook and have made a book. I would like to embed a You Tube file and it seems it is not as simple as slecting an HTML widget and then dropping in the Youtube embed code. Or is it?
    Instructions are to create a widget and then drag the widget code into the HTML widget in iBooks. I was able to make it as far as to learn I can make my YouTube video a custom dashboard widget using the "File," "Open in Dashboard" method in Safari.
    Once I did this I was able to select the portion of the YouTUBE page and click to make the YouTube widget. Presto, easy as pie. But where is the .wdgt file (and/or other related files to this custom dashboard widget) stored? I was able to find the widget directory in my root but only the preinstalled widgets were there--not the the widget I was able to make with the "File," "Open in Dashboard" method.
    Is this the most straightforward way to embed a You Tube file, or is there another way?
    It seems this should/can be as easy as just dropping the embed code into the HTML widget in iBooks. perhaps a consideration for the next version of iBooks...
    Lov'in the Apple experience

    We use a container thats ratio matches the video and insert following format into the folio overlay controls for Web Content: https://www.youtube.com/embed/ jyOFS5lAG68    *PLEASE NOTE: there is a space between the embed/ the video ID.  Remove it to see how the video looks when you paste the link.
    We found this works on both iOS and Android.
    -Ry-

  • Soundcloud widget code won't preview in Muse.

    Trying to share a podcast from Soundcloud, so I copied/pasted the widget code link into Adobe Muse (v4.1). Under Object menu I chose Insert HTML... and pasted the correct code:
    <iframe width="100%" height="166" scrolling="no" frameborder="no" src="https://w.soundcloud.com/player/?url=http%3A%2F%2Fapi.soundcloud.com%2Ftracks%2F97900481"></iframe>
    The Soundcloud player won't show up in Muse's Design or Preview mode. Instead it displays "Couldn't connect to the server. Please try again later." and a Soundcloud logo. I tried the same code in iWeb just to verify it, and it DOES work there.
    Any clues as to why it won't work in Muse?
    Thanks,
    Mike

    Yes, it did works after published in Muse! I embeded soundcloud html code into Muse (It did not work in preview mode) as webpage below:
    http://www.uybantochucbaucu.com/radio-video.html
    _ Try to publish, and see what happens ?!

  • Lost Spry Menu Widget Code

    Please help -
    I have somehow lost the code that allows me to use the SPry
    menu widget to edit my horizontal spry menu. The drop down menu I
    created for my site template using the Spry menu bar works fine and
    my page looks great when I preview. But now widget no longer
    exists. I still have all my original spry assets and CSS. It looks
    like I may have to recreate the page and drop downs all over again
    - -is there a way to "reimport" the spry assets and css to save
    time in recreating my page? Any idea why my widget code got
    deleted?

    You could change this part of the css file for the menu in
    your spry assets folder.
    SpryMenuBarVertical.css
    Try changing the 95% to -95%.
    /* Submenus should appear slightly overlapping to the right
    (95%) and up (-5%) with a higher z-index, but they are initially
    off the left side of the screen (-1000em) */
    ul.MenuBarVertical ul
    margin: -5% 0 0 95%;
    padding: 0;
    list-style-type: none;
    font-size: 100%;
    position: absolute;
    z-index: 1020;
    cursor: default;
    width: 8.2em;
    left: -1000em;
    top: 0;
    Also change this for the pointer gif that shows. Its in the
    SPryAssets folder also.
    Change the 95% to 2% and you can use Photoshop to flip the
    image to point to the right, or left direction.
    /* Menu items that are open with submenus have the class
    designation MenuBarItemSubmenuHover and are set to use a "hover"
    background image positioned on the far left (95%) and centered
    vertically (50%) */
    ul.MenuBarVertical a.MenuBarItemSubmenuHover
    background-image: url(SpryMenuBarRightHover.gif);
    background-repeat: no-repeat;
    background-position: 95% 50%;
    }

  • Spry validation disappears - leaves widget code

    I have added the spry validation to my form fields many
    times. This particular form, I have had to add them twice already
    and now I got an error that says the javascript for widgets that
    are missing are still on the page. I see the widget javascript at
    the bottom of my page in code view. I also see other changes I made
    to the form fields at the same time that I added the spry
    validation. So I am not imagining that I already did this.
    What could have happened to make the validation disappear?
    has this every happened to any of you?

    Hi Daniel,
    Im having the same problem, can you please tell me what you did? I understand you found the problem?
    Thank you!

  • How to embed widget code in a page or template?

    Hi All - I have been using Dreamweaver 8 for a little over a year and still feel like I'm stumbling along...
    The idea of Widgets is fairly new to me but from all the "Free Widget" sites, I got the idea that it was as easy as cut & paste into the page code...
    Okay, something isn't right... the code shows up on the page as text, not the nice little widget iself.
    HOW do I go about getting these little apps to work on my site?
    I have the macromedia extension manager, but is it an extension or is it the code itself and how to place it that matters?
    Help! .. I am really unsure about anything involving code...so please use small words!
    Thanks!

    journalgrrl wrote:
    I am sorry, I thought it was pretty straightforward... if Dreamweaver is supposed to be designer-friendly.
    It depends what you mean by "designer-friendly". Dreamweaver is a professional web development tool. It speeds up the development of websites using  HTML, CSS, JavaScript, and other web-related languages. If you have been using it for a year and still feel you're stumbling along, it sounds as though you don't understand the tool you're trying to use. Without a sound knowledge of HTML and CSS, Dreamweaver will always remain an uphill struggle.
    If you understand the web technologies you're working with, cutting and pasting a widget isn't particularly difficult. But if you don't understand JavaScript and how it interacts with HTML, the process becomes more difficult.
    I see that you're new to the forum. Please take a few moments to read How to get help quickly. One of the things it explains is that it's always a good idea to put an example of the problem you're having on a website and post the URL. By seeing things in context, it's much easier for others to help you. Solving your problem may be something that can be fixed in a jiffy, or it might be much more complicated. At the moment, though, your question is far too vague. It's like ringing up a garage and saying your car isn't running well. The first thing the mechanic will tell you is to bring it in so he can look at it.
    You have posted this question in the Dreamweaver Application Development forum, which deals mainly with PHP, ASP, and other server-side languages. I'm moving this thread to the main Dreamweaver forum, which has more users who might be able to offer further advice.

  • Widget code error

    I try to learn how to create Widgets by the seat of my pants.
    I enjoy reading the Widget king's blog(http://www.infosemantics.com.au/widgetking/blog-2/page/10/)
    I assume I can use the exact same code four times in four different modes from his first code example : enterStage(), enterRuntime(), enterPropertiesDialogue(), and
    enterPropertiesDialogPreview()
    I play with one of his code examples and copied the exact same code in enterPropertiesDialog()
    (His original code is only for enterRuntime...) Then, I got an error message, saying that "Duplicate function definition."
    What is the solution for this? Apparently, we cannot use the same function more than once in AS3.
    Widget experts, please tell me what I miss here. The code example is in the following. The same code is repeated twice.
    package  {
        import flash.display.Sprite;
        import flash.text.TextField;
        import flash.text.TextFieldAutoSize;
        import flash.events.MouseEvent;
        import flash.filters.GlowFilter;
        import fl.controls.TextInput;
        import fl.controls.Button;
        import widgetfactory.StaticWidget;
        public class RuntimeDragger extends StaticWidget {
            // The space between the edges
            private const PADDING:int = 5;
            // UI
            private var message:TextField;
            private var textInput:TextInput;
            // The object on slide that we are currently interacting with.
            private var activeSlideObject:Sprite;
            // The starting location of the active object
            private var orgX:Number;
            private var orgY:Number;
            public function RuntimeDragger() {
                       super(300, 300);
            override protected function enterPropertiesDialog():void
                ///// Create feed back text field
                message = new TextField();
                addChild(message);
                message.autoSize = TextFieldAutoSize.CENTER;
                message.text = "Write the name of the object you want to access.";
                message.x = PADDING;
                message.y = PADDING;
                ///// Create field to write slide object name
                textInput = new TextInput();
                addChild(textInput);
                textInput.width = message.width;
                textInput.x = PADDING;
                // Position under message text field
                textInput.y = message.y + message.height + 5;
                // Default to choosing the highlight box
                textInput.text = "highlightBox";
                ///// Button to click to start dragging a different object
                var startDragButton:Button = new Button();
                addChild(startDragButton);
                startDragButton.width = textInput.width / 2;
                // Centered to text input field
                startDragButton.x = textInput.width / 2 - startDragButton.width / 2 + PADDING;
                // Position under text input field
                startDragButton.y = textInput.y + textInput.height + 5;
                startDragButton.label = "Start Dragging";
                startDragButton.addEventListener(MouseEvent.CLICK, onButtonClick);
                // Simulate a click to start default behaviour.
                onButtonClick();
            private function onButtonClick(e:MouseEvent = null):void
                if (activeSlideObject != null) { // If we have been dragging something before the new object
                    // Return it to its starting position
                    activeSlideObject.x = orgX;
                    activeSlideObject.y = orgY;
                    // Stop dragging behaviour.
                    activeSlideObject.removeEventListener(MouseEvent.MOUSE_DOWN, onDown);
                    onUp();
                    // Remove indicators that you can drag this object.
                    activeSlideObject.filters = [];
                    activeSlideObject.mouseEnabled = false;
                // The object that we've written in the text input field will become draggable
                activeSlideObject = getSlideObjectByName(textInput.text);
                if (activeSlideObject == null) { // If the user didn't write the name correctly
                    message.text = "Could not find an object by the name of: " + textInput.text;
                } else { // User did write the name correctly
                    // Reset message
                    message.text = "Write the name of the object you want to access.";
                    // Start dragging behaviour
                    activeSlideObject.addEventListener(MouseEvent.MOUSE_DOWN, onDown);
                    // Save new object's starting position.
                    orgX = activeSlideObject.x;
                    orgY = activeSlideObject.y;
                    // Create visual indicators that you can now drag this object.
                    activeSlideObject.filters = [new GlowFilter(0xFF0000)];
                    activeSlideObject.mouseEnabled = true;
            override protected function enterRuntime():void
                ///// Create feed back text field
                message = new TextField();
                addChild(message);
                message.autoSize = TextFieldAutoSize.CENTER;
                message.text = "Write the name of the object you want to access.";
                message.x = PADDING;
                message.y = PADDING;
                ///// Create field to write slide object name
                textInput = new TextInput();
                addChild(textInput);
                textInput.width = message.width;
                textInput.x = PADDING;
                // Position under message text field
                textInput.y = message.y + message.height + 5;
                // Default to choosing the highlight box
                textInput.text = "highlightBox";
                ///// Button to click to start dragging a different object
                var startDragButton:Button = new Button();
                addChild(startDragButton);
                startDragButton.width = textInput.width / 2;
                // Centered to text input field
                startDragButton.x = textInput.width / 2 - startDragButton.width / 2 + PADDING;
                // Position under text input field
                startDragButton.y = textInput.y + textInput.height + 5;
                startDragButton.label = "Start Dragging";
                startDragButton.addEventListener(MouseEvent.CLICK, onButtonClick);
                // Simulate a click to start default behaviour.
                onButtonClick();
            private function onButtonClick(e:MouseEvent = null):void
                if (activeSlideObject != null) { // If we have been dragging something before the new object
                    // Return it to its starting position
                    activeSlideObject.x = orgX;
                    activeSlideObject.y = orgY;
                    // Stop dragging behaviour.
                    activeSlideObject.removeEventListener(MouseEvent.MOUSE_DOWN, onDown);
                    onUp();
                    // Remove indicators that you can drag this object.
                    activeSlideObject.filters = [];
                    activeSlideObject.mouseEnabled = false;
                // The object that we've written in the text input field will become draggable
                activeSlideObject = getSlideObjectByName(textInput.text);
                if (activeSlideObject == null) { // If the user didn't write the name correctly
                    message.text = "Could not find an object by the name of: " + textInput.text;
                } else { // User did write the name correctly
                    // Reset message
                    message.text = "Write the name of the object you want to access.";
                    // Start dragging behaviour
                    activeSlideObject.addEventListener(MouseEvent.MOUSE_DOWN, onDown);
                    // Save new object's starting position.
                    orgX = activeSlideObject.x;
                    orgY = activeSlideObject.y;
                    // Create visual indicators that you can now drag this object.
                    activeSlideObject.filters = [new GlowFilter(0xFF0000)];
                    activeSlideObject.mouseEnabled = true;
            // On mouse down start dragging.
            private function onDown(e:MouseEvent):void
                activeSlideObject.startDrag();
                stage.addEventListener(MouseEvent.MOUSE_UP, onUp);
            // On mouse up stop dragging.
            private function onUp(e:MouseEvent = null):void
                activeSlideObject.stopDrag();
                stage.removeEventListener(MouseEvent.MOUSE_UP, onUp);

    Hi shh1cd,
    With ActionScript you cannot create two functions with the same name. In your code above you have two functions called onButtonClick. This is why Flash is reporting an error. If you delete one of those functions, save and then publish again, your code should work.
    The idea behind a function is that it contains a block of code that you can run over and over again and therefore not have to write that code multiple times. So each time you want to call the onButtonClick function, you don't need to write another onButtonClick function. It doesn't matter if you're in the enterRuntime or enterPropertiesDialog, they will both call the one onButtonClick function in your code.
    Tristan,

  • IWeb HTML Widget Code

    Hi, I have a couple of HTML widgets on my site (they are games) that aren't displaying correctly. My other HTML widgets work great but these don't. Here's a link to the games page where you can pick a game and diagnose my problem. http://imasterweb.net/Site/Games.html

    This is the code:
    <iframe height="XXXpx" allowTransparency="true" frameborder="0" scrolling="no" style="width:XXXpx;border:none" src="URL TO ITEM TO BE EMBEDDED"></iframe>
    OT

  • Trying to delete widget code and stop Error message

    I am a little new to CS4:  and receiving an validation error message  on a page about a accordion widget still being on my page and ppotential  problems at runtime.  I look and it is greyed out so i  am not able to remove(delete) the error offending line.  I had  originally removed the accordion widget on purpose but in the process of  removing everything else ( script, etc.) I think I did the removal in  the wrong  sequence or something.
    Can anyone please give  me suggestions on how I might fully remove this widget error line so I  can clean up my code and ensure a clean run.
    thx

    here is the message  I receive when I open the page in CS4
    This document contains javascript code of a widget that no longer exists.
    If you don't remove the code, the browser might displayjavascript errors when loading the page.
    would you like Dreamweaver to find all instances of this code for you???
    widget:var Accordion1=newSpry.Widget.Accordion("cmp_panningcards")
    then shows line inside code, but grayed out so I cannot delete....

  • Can any one teach me how to create a flashplayer widget code

    my site is www.mkufubeats.com and i wanted to have a flashplayer widget with an http://www.mkufubeats.comembed code which i can embed on other websites and that different users on my site can use? how can i get a script of that kind?

    Take a look at my issue with AMS http://forums.adobe.com/thread/1233919

  • Purechat Widget Code HTML embed not Working...

    Hi handy helper people,
    I currently have a client site that's live that has requested adding an HTML embed from Purechat.com for their chat widget. After inserting the HTML it will not recognize and get a "unable to generating thumbnail" text.
    Anyone know a fix for this? Your knowledge is greatly appreciated!!

    Hi Vivek,
    Thank you for your reply and help. Yes, that's been tested, it isn't viewable in browser or when published live.
    Site: www.genaltapower.com
    Purechat code embed:
    <script type='text/javascript'>(function () { var done = false; var script = document.createElement('script'); script.async = true; script.type = 'text/javascript'; script.src = 'https://widget.purechat.com/VisitorWidget/WidgetScript'; document.getElementsByTagName('HEAD').item(0).appendChild(script); script.onreadystatechange = script.onload = function (e) { if (!done && (!this.readyState || this.readyState == 'loaded' || this.readyState == 'complete')) { var w = new PCWidget({ c: '2a6ac48a-ecad-41ab-8ebc-92a2a2fe063e', f: true }); done = true; } }; })();</script>
    Regards,
    Jason

  • Need help with a widget code please

    Hello everyone and Happy Holidays
    I have been trying to learn some simple codes for the widgets and here is one that does some of what I want but I cannot get the line that create the send to an email address work
    <FORM ACTION="/cgi-bin/html/formdump.cgi"
    METHOD="GET" ENCTYPE="application/x-www-form-urlencoded">
    E-mail address: <INPUT TYPE="text" NAME="email" SIZE="20">
    <INPUT TYPE="radio" NAME="abonnement" VALUE="s'abonner" CHECKED> s'abonner
    <INPUT TYPE="radio" NAME="abonnement" VALUE="se désabonner"> se désabonner
    <INPUT TYPE="submit" VALUE="Submit">
    </FORM>
    another line I would like to add is a size so the box is formatted properly but everytime I do that I mess up things more.
    Thank you for your help
    Mireille

    thank you Kirk,
    You are correct in saying that I do not want to go there. Tough code is not for me
    So how can I have a form where people choose subscribe or unsubscribe then when they submit I get an email?
    Thanks
    Mireille

  • What's wrong with this widget code?

    Hi everyone,
    (I hope this is a good place to put this) I'm trying to build a widget in Dashcode, and one of the things I want to do is run a system command (specifically "ps -ax"). I enabled command line access in the widget attributes, and I now have:
    var processes = widget.system("/bin/ps -ax", NULL);
    The problem is that "processes" is always undefined. I read on here that there's a bug that if the output is too long, then the variable is undefined. So I tried substituting the command with this:
    var processes = widget.system("/bin/ls ~/", NULL);
    When I run the command in Terminal, the output is minimal:
    Desktop Documents Downloads Library Movies Music Pictures Public Sites
    But when I try to run that in Dashcode, it still returns undefined. Am I missing something obvious here?

    bump I'm still at a standstill with this. Any ideas?
    Thanks!

  • Adding full screen code into Captivate 5's basic Button Widget

    Hi everyone!
    I was able to create a full screen button in Flash that works with Captivate 5 projects, however, I want to be able to active the full screen feature for every button created using the basic 'button' widget that comes with the Captivate program.  I am not a AS3 programmer so I think my issue is that I am confused as  to where to place the full screen code into the existing 'button widget'  code. Below is the code ...
    Thanks in advance!!
    edlearner
    HERE IS THE FULLSCREEN CODE THAT I USE
    button_name.addEventListener(MouseEvent.CLICK, fullScreen_action);
    function fullScreen_action(event:MouseEvent):void {
    stage.displayState=StageDisplayState.FULL_SCREEN;
    stop();
    HERE IS THE BASIC CODE FOR THE BUTTON WIDGET IN CAPTIVATE 5
    //..........................Template for Static Widget(AS3)....................
    //flash construct to use external interface : This is needed to use flash functionality for communication between two swfs
    import flash.external.ExternalInterface;
    import fl.controls.ComboBox;
    var widgetMode:String = '';
    var widgetParam:String = '';
    var varHand:Object = null;
    var movieHandle:Object = null;
    XML.prettyIndent = 0;
    XML.prettyPrinting = false;
    XML.ignoreWhitespace = true;
    var checkUpdatedXML = false;
    var playedByButton = false;
    var pauseFrame = 0;
    var addednoskipframe = false
    var myXML:XML;
    var myData:String = '<element1><textProperties><font face="Trebuchet MS" style="" size="12"/><textDecoration bold="true" underline="false" italic="false"/><color textColor="0x000000" highlightRequired="false" highlightColor="0xffffff"/></textProperties><captions style="BUTTON_1" themeLabel="0" backColor="0xffffcc" eventAssign="" eventParam="" txtXPos="9" txtYPos="4" imgXPos="190" imgYPos="40" a="1" b="0" c="0" d="1" tx="0" ty="0" bgSelected="false" borderColor="0xff9933" borderSelected="false" containerXPos="" containerYPos=""><text visible="true" width="42" height="20" a="1" b="0" c="0" d="1" tx="18" ty="4">Button</text><image visible="false" width="22" height="18" a="1" b="0" c="0" d="1" tx="NaN" ty="NaN"></image></captions></element1>';
    var xmlConfig:String = '<configs><styles label="Ivory" movieclip="BUTTON_1" backColor=""/><styles label="Frosted" movieclip="BUTTON_8" backColor=""/><styles label="Grey Space" movieclip="BUTTON_9" backColor=""/><styles label="Honey Comb" movieclip="BUTTON_10" backColor=""/><styles label="Mountain Blue" movieclip="BUTTON_11" backColor=""/><styles label="Aero" movieclip="BUTTON_12" backColor=""/><styles label="Gradient" movieclip="BUTTON_13" backColor=""/><styles label="Vivid 1" movieclip="BUTTON_14" backColor=""/><styles label="Vivid 2" movieclip="BUTTON_15" backColor=""/><styles label="Aqua" movieclip="BUTTON_16" backColor=""/><styles label="Glitter" movieclip="BUTTON_17" backColor=""/></configs>';
    //var xmlConfig:String = '<configs><styles label="Button 1" movieclip="BUTTON_1" backColor=""/><styles label="Button 2" movieclip="BUTTON_2" backColor=""/><styles label="Button 1" movieclip="BUTTON_1" backColor=""/><styles label="Button 2" movieclip="BUTTON_2" backColor=""/><styles label="Button 3" movieclip="BUTTON_3" backColor=""/><styles label="Button 4" movieclip="BUTTON_4" backColor=""/></configs>';
    var myConfig:XML = new XML(xmlConfig);
    var myWM = "";
    var mc:MovieClip;
    CaptionMc.visible = false;
    textFormatterMc.visible = false;
    //update ();
    var objName;
    function fnHandleButtonEvent (evt:MouseEvent)
        if (varHand != null)
            switch (Number(myXML.captions.@eventAssign))
                case 1 :
                    varHand.rdcmndResume = 1;
                    break;
                case 2 :
                    varHand.rdcmndPrevious = 1;
                    break;
                case 3 :
                    varHand.rdcmndNextSlide = 1;
                    break;
                case 4 :
                    varHand.cpCmndGotoSlide = varHand.cpInfoLastVisitedSlide;
                    varHand.rdcmndResume = 1;
                    break;
                case 5 :
                    if(varHand.rdinfoCurrentSlide != (Number(myXML.captions.@eventParam) - 1)){
                        varHand.cpCmndGotoSlide = Number(myXML.captions.@eventParam) - 1;
                        varHand.rdcmndResume = 1;
                    break;
                case 6 :
                    navigateToURL (new URLRequest(myXML.captions.@eventParam), "_blank");
                    break;
                case 7 :
                    navigateToURL (new URLRequest("mailto:"+myXML.captions.@eventParam), "_blank");
                    break;
            playedByButton = true;
    function update ()
        myXML = new XML(myData);
        if (myWM == "Edit")
            textFormatterMc.setData (myXML.textProperties);//strCaptivateXML:String
            textFormatterMc.init ();
            CaptionMc.setData (myXML.captions, textFormatterMc);
            CaptionMc.setConfig (myConfig.styles);
            CaptionMc.init ();
            CaptionMc.visible = true;
            textFormatterMc.visible = true;
            var arr = [textFormatterMc.sizeSelectorMc];
            initCursor(arr);
        else
            CaptionMc.visible = false;
            textFormatterMc.visible = false;
            if(mc != null){
                removeAllChildren(mc);
            }else{
                mc = new MovieClip();
                addChild (mc);
            var xmlRef = myXML.captions;
            var textMatrix:Matrix = new Matrix(xmlRef.text.@a, xmlRef.text.@b, xmlRef.text.@c, xmlRef.text.@d, xmlRef.text.@tx, xmlRef.text.@ty)
            var txt:TextField = new TextField();
            objName = txt;
            txt.name = "txt";
            txt.mouseEnabled = false;
            txt.selectable = false;
            txt.multiline = true;
            txt.wordWrap = true;
            mc.addChild (txt);
            txt.text = xmlRef.text;
            txt.mouseEnabled = false;
            txt.width = Number(xmlRef.text.@width);
            txt.height = Number(xmlRef.text.@height);
            //txt.x = Number(xmlRef.text.@tx);
            //txt.y = Number(xmlRef.text.@ty);
            txt.transform.matrix = textMatrix;
            var txtProp = myXML.textProperties;
            var tf = new TextFormat(txtProp.font. @ face,txtProp.font. @ size,txtProp.color. @ textColor,getBool(txtProp.textDecoration. @ bold),getBool(txtProp.textDecoration. @ italic),getBool(txtProp.textDecoration. @ underline));
            txt.setTextFormat (tf);
            if (txtProp.color. @ highlightRequired == "true")
                txt.background = true;
                txt.backgroundColor = uint(txtProp.color. @ highlightColor);
            txt.visible = getBool(xmlRef.text. @visible)
            var mcCaption = new MovieClip();
            var mcCaptionMatrix = new Matrix(xmlRef.@a, xmlRef.@b, xmlRef.@c, xmlRef.@d, xmlRef.@tx, xmlRef.@ty);
            var ClassName:Class = getDefinitionByName(xmlRef.@style) as Class;
            var objHolder = new ClassName();
            objHolder.buttonMode = true;
            objHolder.addEventListener (MouseEvent.CLICK, fnHandleButtonEvent);
            mcCaption.addChild (objHolder);
            objHolder.transform.matrix = mcCaptionMatrix;
            if (SimpleButton(objHolder.getChildByName("btn")) != null && xmlRef.@bgSelected == "true")
                var tempColorStr = [email protected]();
                if (tempColorStr.length > 0)
                    var objColorTransform = new ColorTransform();
                    objColorTransform.color = uint(tempColorStr);
                    SimpleButton(objHolder.getChildByName("btn")).transform.colorTransform = objColorTransform;
            if (MovieClip(objHolder.getChildByName("mcBorder")) != null && xmlRef.@borderSelected == "true")
                var borderColorStr = [email protected]();
                if (borderColorStr.length > 0)
                    var borderColorTransform = new ColorTransform();
                    borderColorTransform.color = uint(borderColorStr);
                    MovieClip(objHolder.getChildByName("mcBorder")).transform.colorTransform = borderColorTransform;
            mcCaption.addChild (objHolder);
            mc.addChildAt (mcCaption, 0);
            var mcIconMatrix = new Matrix(xmlRef.image.@a, xmlRef.image.@b, xmlRef.image.@c, xmlRef.image.@d, xmlRef.image.@tx, xmlRef.image.@ty)
            var mcIcon = new Loader();//IconMovie();
            mcIcon.contentLoaderInfo.addEventListener (Event.COMPLETE, imageLoaded);
            if (xmlRef.image != ""){
                mcIcon.load (new URLRequest(String(xmlRef.image)));
            mcIcon.name = "mcIcon";
            mcIcon.transform.matrix = mcIconMatrix;
            mcIcon.visible = getBool(xmlRef.image. @visible)
            mc.addChild (mcIcon);
    var cursor;
    var otherCursor;
    var downState = false;
    function initCursor(arr:Array){
        cursor = new Cursor();
        cursor.mouseEnabled = false
        cursor.visible = false;
        addChild(cursor);
        otherCursor = new StretchCursor();
        otherCursor.mouseEnabled = false
        otherCursor.visible = false;
        addChild(otherCursor);
        for(var i=0 ; i< arr.length; i++){
            arr[i].addEventListener(MouseEvent.ROLL_OVER, showCursor)
            arr[i].addEventListener(MouseEvent.ROLL_OUT, hideCursor)
            arr[i].addEventListener(MouseEvent.MOUSE_DOWN, showOtherCursor)
            arr[i].addEventListener(MouseEvent.MOUSE_UP, hideOtherCursor)
        this.addEventListener(MouseEvent.MOUSE_UP, hideOtherCursor);
        this.addEventListener(MouseEvent.ROLL_OUT, hideOtherCursor);
    function showCursor(e:MouseEvent){
        var txt = MovieClip(e.target).sizeTxt;
        if(!downState && txt.type == "dynamic"){
            cursor.visible = true;
            cursor.startDrag(true)
            Mouse.hide();
    function hideCursor(e:MouseEvent){
        if(!downState){
            cursor.stopDrag()
            cursor.visible = false;
            Mouse.show();
    function showOtherCursor(e:MouseEvent){
        var txt = MovieClip(e.currentTarget).sizeTxt;
        if(txt.type == "dynamic"){
            hideCursor(e);
            downState = true
            otherCursor.startDrag(true)
            otherCursor.visible = true;
            Mouse.hide();
    function hideOtherCursor(e:MouseEvent){
        downState = false;
        otherCursor.stopDrag()
        otherCursor.visible = false;
        Mouse.show();
    function removeAllChildren(mcRef:MovieClip){
        for(var i=(mcRef.numChildren-1); i>=0; i--){
            mcRef.removeChildAt(i);
    function imageLoaded (e:Event)
        var mc = e.target.content;
        mc.width = Number(myXML.captions.image. @ width);
        mc.height = Number(myXML.captions.image. @ height);
    function getBool (str:String):Boolean
        var ret:Boolean;
        if (str == "true")
            ret = true;
        else
            ret = false;
        return ret;
    function getModifiedXML ():String
        return myXML.toString();
    //to register enter frame function
    this.addEventListener (Event.ENTER_FRAME,onEnterEveryFrame);
    //Captivate App will not recognize a Static Widget unless this function is implemented and returns true
    function isStatic ():Boolean
        return true;//denotes that this is indeed a Captivate Interactive Learning Object
    //a object needs to be created and values filled in . This is taken by captivate and stored as //xml string. This is the mean to pass values between captivate and widget swf.
    function getInspectorParameters ():Object
        //dev//Apply
        //set the data in _parameters fields. This is called by captivate to get the values of widget swf
        var _parameters: Object = new Object();
        _parameters.dataXML = getModifiedXML();
        return _parameters;
    // whenever widget is inserted the widget swf is passed on the parameters stored inside captivate so that it is drawn in updated stage.
    function setInspectorParameters (inParam:Object):void
        //Dev//on Double click //edit window
        myData = inParam.dataXML;
        myWM = widgetMode;
        update ();
    //is called whenever widget needs to be drawn as per the changed
    //parameters like OK to widget dialog and stage swf is updated with the current values.
    function setParameters (inParam:Object):void
        if (inParam.dataXML != null)
            //redraw the widget as parameters has changed
            //dev//OK button
            myData = inParam.dataXML;
            myWM = widgetMode;
            update ();
    //this function is called to set the variable on player
    function cpSetValue (variable:String, val):void
        if (variable == 'movieHandle')
            movieHandle = val;
            varHand = movieHandle.getMovieProps().variablesHandle;
            //using varHand the variables can be accessed for eg. varHand.rdcmndPause = 1;
        if (variable == 'widgetMode')
            widgetMode = val;
            //dev//set mode
    function getEditModeWidth ( ):int
        return 411;// return required width of widget properties dialog here
    function getEditModeHeight ( ):int
        return 480;// return required height of widget properties dialog here
    //Register all the functions with ExternalInterface
    if (ExternalInterface.available == true)
        ExternalInterface.addCallback ("isStatic",isStatic);
        ExternalInterface.addCallback ("getInspectorParameters",getInspectorParameters);
        ExternalInterface.addCallback ("setInspectorParameters",setInspectorParameters);
        ExternalInterface.addCallback ("setParameters",setParameters);
        ExternalInterface.addCallback ("cpSetValue", cpSetValue);
        ExternalInterface.addCallback ( "getEditModeWidth", getEditModeWidth);
        ExternalInterface.addCallback ( "getEditModeHeight", getEditModeHeight);
    //take care of optimised drawing inside this function. Check the widgetMode , widgetParams  and draw accordingly
    function onEnterEveryFrame (aevent:Event):void
        var wm:String = widgetMode;//this variable will be provided by Captivate App or Captivate Movie
        if (wm == null)
            wm = widgetMode;
        if (wm == null)
            wm = 'Stage';
            this.removeEventListener (Event.ENTER_FRAME,onEnterEveryFrame);
        else if (wm == 'Edit')
            //Property inspection inside Captivate app
            myWM = wm;
            update ();
            this.removeEventListener (Event.ENTER_FRAME,onEnterEveryFrame);
        else if (wm == 'Preview')
            //The code here is used for previewing the widget in the preview window of widget panel
            myWM = wm;
            update ();
            this.removeEventListener (Event.ENTER_FRAME,onEnterEveryFrame);
        else
            //On stage scrubbing/live preview inside Captivate app (OR) at runtime inside Captivate movie.
            if(!checkUpdatedXML){
                if (movieHandle != null)
                    widgetParam = movieHandle.widgetParams();
                if (widgetParam != "")
                    var myXml:XML = new XML(widgetParam);
                    myData = myXml.property.(@id == "dataXML").string;
                    wm = "Runtime";
                    myWM = wm;
                    update ();
                    checkUpdatedXML = true
            if (movieHandle != null)
                if (movieHandle.isWidgetEnabled() == true)
                    if(addednoskipframe == false)
                        var slidestart = movieHandle.getSlideProps().startFrame;
                        var slideend = movieHandle.getSlideProps().endFrame;
                        pauseFrame = Math.ceil((slidestart  + slideend)/2);
                        var SlidePauseFrame = pauseFrame - slidestart + 1;
                        movieHandle.getSlideProps().slideHandle.AddNoSkipFrame(SlidePauseFrame);
                        addednoskipframe = true;
                    if(movieHandle.isWidgetEnabled()  && varHand.rdinfoCurrentFrame == pauseFrame && playedByButton == false)
                        varHand.rdcmndPause = 1;
                        this.removeEventListener (Event.ENTER_FRAME,onEnterEveryFrame);
    stage.scaleMode = StageScaleMode.NO_SCALE;
    stage.align = StageAlign.TOP_LEFT;

    Hi again,
    I just added a virtual keyboard widget, so that you can enter text even in Fullscreen Mode
    http://www.m-gd.com/virtual-keyboard-captivate-widget-en/

  • Editing swfobject.js code so hyperlinks inside the flash widget open in a new window

    0down votefavorite
    I have a flash calendar widget (code shown directly below) and I do not have access to anything other than the compiled .swf file (no access to .fla).
    The widget contains some hyperlinks to other websites, these links are dynamic and changes based on a number of things.
    There is also a corresponding swfobject.js file that is used to add functionality to the flash widget. The swfobject.js code is shown further down this post.
    Currently, the way the code is now, when I click any of the hyperlinks that are available to me in the widget, the destination website that hyperlink takes me to opens in THE SAME PAGE as the flash widget which is a big problem.
    I need to edit the code below so that any hyperlinks that are clicked inside of the flash widget open in a brand new browser window and do not take the user away from the original widget other than opening a new page with new content.
    Because the hyperlinks that are available are always changing, the swfobject code below uses some functions and parameters.
    I am hoping you can show me exactly what code I must insert, and exactly where I must insert it, in order to alter the behavior that happens so that when a user clicks one of the hyperlinks inside the flash widget, so that the content at the other end of the hyperlink opens in a new window, instead of opening in the same window.
    See code below.
    Thank you in advance for any help you can provide
    Flash Widget Code
    <!-- Embedded Calendar --> <div id="activecontent"> <script type="text/javascript" src="swfobject.js"></script> <div id="awccalendar"></div> <script type="text/javascript"> var so = new SWFObject("awc.swf", "awccalendar2", "700", "180", "8", "#ffffff"); so.addVariable('calendarid', '0'); so.addVariable('appurl', ''); // Flash Widget Initial Date should be ddmmyyyy so.addVariable('ldate', '20052014'); so.write('awccalendar'); </script> </div>  <!-- Embedded Calendar -->
    SWFOBJECT.JS CODE
    /** * SWFObject v1.5: Flash Player detection and embed - http://blog.deconcept.com/swfobject/ * * SWFObject is (c) 2007 Geoff Stearns and is released under the MIT License: * http://www.opensource.org/licenses/mit-license.php * */ if(typeof deconcept=="undefined"){var deconcept=new Object();}if(typeof deconcept.util=="undefined"){deconcept.util=new Object();}if(typeof deconcept.SWFObjectUtil=="undefined"){deconcept.SWFObjectUtil=new Object();}deconcept.SWFObject=function(_1,id,w,h,_5,c,_7,_8,_9,_a){if(!document.getElementById){return;}this.DETECT_KEY=_a?_a:"detectflash";this.skipDetect=deconcept.util.getRequestParameter(this.DETECT_KEY);this.params=new Object();this.variables=new Object();this.attributes=new Array();if(_1){this.setAttribute("swf",_1);}if(id){this.setAttribute("id",id);}if(w){this.setAttribute("width",w);}if(h){this.setAttribute("height",h);}if(_5){this.setAttribute("version",new deconcept.PlayerVersion(_5.toString().split(".")));}this.installedVer=deconcept.SWFObjectUtil.getPlayerVersion();if(!window.opera&&document.all&&this.installedVer.major>7){deconcept.SWFObject.doPrepUnload=true;}if(c){this.addParam("bgcolor",c);}var q=_7?_7:"high";this.addParam("quality",q);this.setAttribute("useExpressInstall",false);this.setAttribute("doExpressInstall",false);var _c=(_8)?_8:window.location;this.setAttribute("xiRedirectUrl",_c);this.setAttribute("redirectUrl","");if(_9){this.setAttribute("redirectUrl",_9);}};deconcept.SWFObject.prototype={useExpressInstall:function(_d){this.xiSWFPath=!_d?"expressinstall.swf":_d;this.setAttribute("useExpressInstall",true);},setAttribute:function(_e,_f){this.attributes[_e]=_f;},getAttribute:function(_10){return this.attributes[_10];},addParam:function(_11,_12){this.params[_11]=_12;},getParams:function(){return this.params;},addVariable:function(_13,_14){this.variables[_13]=_14;},getVariable:function(_15){return this.variables[_15];},getVariables:function(){return this.variables;},getVariablePairs:function(){var _16=new Array();var key;var _18=this.getVariables();for(key in _18){_16[_16.length]=key+"="+_18[key];}return _16;},getSWFHTML:function(){var _19="";if(navigator.plugins&&navigator.mimeTypes&&navigator.mimeTypes.length){if(this.getAttribute("doExpressInstall")){this.addVariable("MMplayerType","PlugIn");this.setAttribute("swf",this.xiSWFPath);}_19="<embed type=\"application/x-shockwave-flash\" src=\""+this.getAttribute("swf")+"\" width=\""+this.getAttribute("width")+"\" height=\""+this.getAttribute("height")+"\" style=\""+this.getAttribute("style")+"\"";_19+=" id=\""+this.getAttribute("id")+"\" name=\""+this.getAttribute("id")+"\" ";var _1a=this.getParams();for(var key in _1a){_19+=[key]+"=\""+_1a[key]+"\" ";}var _1c=this.getVariablePairs().join("&");if(_1c.length>0){_19+="flashvars=\""+_1c+"\"";}_19+="/>";}else{if(this.getAttribute("doExpressInstall")){this.addVariable("MMplayerType","ActiveX");this.setAttribute("swf",this.xiSWFPath);}_19="<object id=\""+this.getAttribute("id")+"\" classid=\"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000\" width=\""+this.getAttribute("width")+"\" height=\""+this.getAttribute("height")+"\" style=\""+this.getAttribute("style")+"\">";_19+="<param name=\"movie\" value=\""+this.getAttribute("swf")+"\" />";var _1d=this.getParams();for(var key in _1d){_19+="<param name=\""+key+"\" value=\""+_1d[key]+"\" />";}var _1f=this.getVariablePairs().join("&");if(_1f.length>0){_19+="<param name=\"flashvars\" value=\""+_1f+"\" />";}_19+="</object>";}return _19;},write:function(_20){if(this.getAttribute("useExpressInstall")){var _21=new deconcept.PlayerVersion([6,0,65]);if(this.installedVer.versionIsValid(_21)&&!this.installedVer.versionIsValid(this.getAttribute("version"))){this.setAttribute("doExpressInstall",true);this.addVariable("MMredirectURL",escape(this.getAttribute("xiRedirectUrl")));document.title=document.title.slice(0,47)+" - Flash Player Installation";this.addVariable("MMdoctitle",document.title);}}if(this.skipDetect||this.getAttribute("doExpressInstall")||this.installedVer.versionIsValid(this.getAttribute("version"))){var n=(typeof _20=="string")?document.getElementById(_20):_20;n.innerHTML=this.getSWFHTML();return true;}else{if(this.getAttribute("redirectUrl")!=""){document.location.replace(this.getAttribute("redirectUrl"));}}return false;}};deconcept.SWFObjectUtil.getPlayerVersion=function(){var _23=new deconcept.PlayerVersion([0,0,0]);if(navigator.plugins&&navigator.mimeTypes.length){var x=navigator.plugins["Shockwave Flash"];if(x&&x.description){_23=new deconcept.PlayerVersion(x.description.replace(/([a-zA-Z]|\s)+/,"").replace(/(\s+r|\s+b[0-9]+)/,".").split("."));}}else{if(navigator.userAgent&&navigator.userAgent.indexOf("Windows CE")>=0){var axo=1;var _26=3;while(axo){try{_26++;axo=new ActiveXObject("ShockwaveFlash.ShockwaveFlash."+_26);_23=new deconcept.PlayerVersion([_26,0,0]);}catch(e){axo=null;}}}else{try{var axo=new ActiveXObject("ShockwaveFlash.ShockwaveFlash.7");}catch(e){try{var axo=new ActiveXObject("ShockwaveFlash.ShockwaveFlash.6");_23=new deconcept.PlayerVersion([6,0,21]);axo.AllowScriptAccess="always";}catch(e){if(_23.major==6){return _23;}}try{axo=new ActiveXObject("ShockwaveFlash.ShockwaveFlash");}catch(e){}}if(axo!=null){_23=new deconcept.PlayerVersion(axo.GetVariable("$version").split(" ")[1].split(","));}}}return _23;};deconcept.PlayerVersion=function(_29){this.major=_29[0]!=null?parseInt(_29[0]):0;this.minor=_29[1]!=null?parseInt(_29[1]):0;this.rev=_29[2]!=null?parseInt(_29[2]):0;};deconcept.PlayerVersion.prototype.versionIsValid=function(fv){if(this.major<fv.major){return false;}if(this.major>fv.major){return true;}if(this.minor<fv.minor){return false;}if(this.minor>fv.minor){return true;}if(this.rev<fv.rev){return false;}return true;};deconcept.util={getRequestParameter:function(_2b){var q=document.location.search||document.location.hash;if(_2b==null){return q;}if(q){var _2d=q.substring(1).split("&");for(var i=0;i<_2d.length;i++){if(_2d[i].substring(0,_2d[i].indexOf("="))==_2b){return _2d[i].substring((_2d[i].indexOf("=")+1));}}}return "";}};deconcept.SWFObjectUtil.cleanupSWFs=function(){var _2f=document.getElementsByTagName("OBJECT");for(var i=_2f.length-1;i>=0;i--){_2f[i].style.display="none";for(var x in _2f[i]){if(typeof _2f[i][x]=="function"){_2f[i][x]=function(){};}}}};if(deconcept.SWFObject.doPrepUnload){if(!deconcept.unloadSet){deconcept.SWFObjectUtil.prepUnload=function(){__flash_unloadHandler=function(){};__flash_savedUnloadHandler=function(){};window.attachEvent("onunload",deconcept.SWFObjectUtil.cleanupSWFs);};window.attachEvent("onbeforeunload",deconcept.SWFObjectUtil.prepUnload);deconcept.unloadSet=true;}}if(!document.getElementById&&document.all){document.getElementById=function(

    In that case, I will have no choice but to decompile the .swf to get the .fla because the original .fla is un-obtainable. Unless there is a way to edit the contents of the .swf file without decompiling it.
    I can see the code inside via various decompile tools and it seems that I would need to add the equivalent of <src target=_blank> to some of the lines I have shown below.
    obj_xml.load(appurl + "loadconfig.aspx?calendarid=" + calendarid);  -- need to edit this so it opens in a new window using something similar to target = _blank
    dest_page = appurl + "default.aspx"; -- need to edit this so it opens in a new window using something similar to target = _blank
    I know a lot of decompile tools can get you the code and the .fla but once you edit and re-compile and attempt to replace the original with the new & updated file, the decompiler did not necessarily generate the properly formatted flash pro project file, so compiling it back into an operational .swf often ends in failure.
    Do you know or can you recommend a tool that has a very good track record of re-compiling the decompiled modified.fla into a workable and usable .swf?

Maybe you are looking for

  • Warning - KB2984972 and App-V 4 and App-V 5 Packages

    The above Security Update went on to all of our W7 PC last night as part of Patch Tuesday and broke a large number of our existing 4.6 Autodesk related packages. AutoCAD itself was not affected but Revit, Navis, DWG TrueView all were. Not got to the

  • Procure to Asset  Complete Cycle

    Does anybody know all setups required to complete cycle from creating an item for asset ,creating PO, transfering asset to FA(rather than inventory) and paying this invoice etc .does any body have this test cycle-

  • Production order enhancement

    Hi, I would like to add one more tab page (Customer screen) in production order(CO01/Co02) header level. Is it possible through configuration? or do I need to do enhancement? Thanks in advance for your valuable inputs. Regards, Alex

  • Settings for optimum use for MBP / Dell 27"

    I recently purchased a Dell 27" monitor (which is lush to use for my MBP main display and xbox360 etc. The MBP display is 1680x1050 but the dell display is 1920x1200 meaning i have to down-rate my display otherwise i have a big blue band around two s

  • Captivate 7 - Incorrect Answers not allowing quiz to Continue. Buttons not functioning correctly (Clear, Back, Next). I have Knowledge Check

    I am experiencing a problem with the Quiz feature of Captivate 7. Correct answers are submitting o.k., but Incorrect answers are not. You cannot go forward with them, i.e., the program will not Continue or go to the next question with an Incorrect an