Flex :: Simple TextField - Using SWFObject To Embed Flash
Nov 20, 2009
I'm using swfobject to embed my flash. I've created a simple textfield using FlexBuilder. It's an AS3 project, which extends Sprite. I've set its width to be 640 and height to 450. Then, in the swfobject parameters of the page, I've also set 640 x 450. I've made the background nice and red and ugly so you can see it. [URL]. It seems to be the right dimensions.
But I've got a textfield which is supposed to be almost the same size and height. This runs fine in FlexBuilder (is the right size) but is all messed up once I add swfobject Can anyone see what is happening? I just looked at it and it looks ok. But then I refreshed the page and the textfield is postage-stamp size (again -- this is the original behavior I saw.) It's now looking OK in firefox but not in IE8. Flash is supposed to look the same in all browsers?
I'm building a website using Flex, Codeigniter, and I use swfobject to embed the swf. This will not work if I access the website using Codeigniter's index.php file. This is the ouput source:
[Code]...
My guess is that swfobject.js is not detected by codeigniter..
I tried SwfObject for loading swf on a website. It is all good with webkit and mozila based browsers but not with IE.[URL].. In IE 8 the footer not loading, it like crashes after the swf loads. In IE 7 the player not working, so the footer loads.
How can I debug it? I have a Mac, Linux, Win7 with IE 8 64 bit. On IE 64-bit it gives a message to update the flash player but there is no update for this player from Adobe.
For some abstract reasons I can't get this to work...No matter how I try to embed my flash with swfobject, the html file doesn't display the flash file.
i am wanting to know how much I can be sure that users of my website will not be able to pass bogus variables to my Flash movie. Basically I will have some features available to certain users and I realise that for the average user they will not know anything about how to send spoof vars but is it possible for someone to change the variables sent using SWFObject when a page loads and thus be able to use the functionality that I am trying to disable for them.I have a PHP (my_flash_movie.php) page that calls a function from an included globals.php file to determine if the user can see the restricted functionality is_ user_a_subscriber($_SESSION['user_id']); which returns 1 or 0. This 1 or 0 is then passed to Flash which enables or disables certain features. I dont want someone to be able to send a 1 instead of a 0 basically. This isnt a site where security is critical and the functionality that is disabled is not really critical either so wouldnt be too bad if this happened but im just curious about this and wondering if I should think of another way to pass these vars that might be more hidden.
I'm using swfobject to load a flash object on my site and it's loading very slowly on pages with a lot of data...as if swfobject waits until the page loads before loading the swf. Here's an example page with swfobject: [URL] If I change out the swfobject code with an iframe (with the swf as the src) or just use object embed, the flash object loads much, much faster...before the rest of the page loads.
I know there are a ton of page load time improvements I could make to that page (I'm working on that as well), but I'm wondering if there are some specific changes I could make to the way I'm using swfobject to get the same loading speed as an iframe or object embed?
I have a simple html page with some javascript where if i click a link, it will show a flash video in a div using the swfobject.embedSWF function. I did a test: Uninstalled flash from my machine, then reloaded the page and clicked the link...I correctly saw no video. I then installed flash and came back to the same page (no reload) and the embed still won't work. I know in swfobject 1.5 (I'm now using 2.2), I would be able to embed the swf after the user installs flash, but now the user needs to reload the page in order to get the flash to appear. This is not good for my current situation, anyone know what is going on here? Here is sample code using a youtube video:
I have tried this and it doesn't seem to work. In the example below the movie on the right (boy in the hat) is embedded using this procedure but the two on the left (paws moving on order button and dog animation) had to be installed using Dreamweaver's swf installation methodology. and, consequently the dog animation does not show up in Explorer 8 and some other browsers.
It works with Firefox and Chrome, but something's not quite right in IE6. Sadly, one of the project requirements is supporting this browser, so even if it workis in IE7, I need to work this out.I know there's SWFObject, but I'd rather not use it (we are loading already a bunch of JS files, we don't want more).Even this won't work:
I added a SWC with movieclip assets to my flash builder project. I can access all movieclips with dot syntax but when I try to access my textfields it throws an error saying it is cannot access a property or method of a null object reference
Here is my code:
// gameMenuLevels is a main asset. this.object = new gameMenuLevels();
This all works fine, I can go two levels deep:
var levelString:String = "level" + Utils.zeroPad(i + 1, 3); var level:MovieClip = this.object[levelString] as MovieClip; var bronze:MovieClip = level.bronze as MovieClip;
But when I try to get my textfield:
(bronze.getChildByName("levelNumber") as TextField)
Is there a script similar to the image below that lets the user press a copy button to copy text to their clipboards (instead of right-clicking to copy)? Here's the URL where I got that image: [URL]. Where I can find a script to do implement that functionality?
How to enable special characters in var txt:TextField = new TextField(); in action script 3.0. var tf:TextFormat = new TextFormat(); tf.font = "Verdana"; tf.size = 12; tf.bold = true; tf.align = "left"; [Code] .....
I embedded the "Verdana" font in ma fla named "Verdana". But my issue is the text filed is not showing the special characters. How can I embed in codes, I don't use the text filed from the component library. Everything was created only through action script 3.0 code.
I'm thinking about setting up a website (based on WordPress) to host video tutorials on interpreting CT scans.
In addition to simply letting the visitor view PowerPoint presentation videos, I'm keen on writing some sort of simple app that I can embed in the blog to allow the visitor to scroll through a series of images (i.e. a scan).
I usually code in REALbasic or Objective-C. What are my language options for making an interactive embeddable image viewer in a blog? The website needs to be able to be viewed on an iPad as well as normal desktop browsers.
With swfobject 2.2, how do you specify the desired version of flash you require? I need flash 10, but swfobject won't perform an upgrade install with the provided expressInstall. swf in the swfobject 2.2 distributable. How do I get an upgrade install to occur for flash 10?
This seems to be a consistent problem when working with htmlText in flash textfields that must be alpha'd. currently i have a clip with two dyn textfields inside it. The textfields are set to 'eurostile' font but NOT embedded. The clip itself has a filter applied to it in the hopes that cacheAsBitmap will be triggered. Offstage i have copies of the two textfields each having the 'basic latin' character set for eurostile embedded. This works locally where i have the font enabled on my system and i'm able to alpha in/out the text, but of course when i upload the font isn't displaying in eurostile (defaulting to Times or somesuch).
We have a flex application which compiles fine on windows box using mxmlc ant task but when we try to run the same build scripts on linux, it throws the 'Invalid Embed directive in stylesheet' error indicating it is not able to resolve the path to the image files.
Can someone pls. educate me on if there is a difference in the way the image files are looked up, in a CSS file, on windows vs linux.
Flex sdk version is 3.3. The same sdk is used on both windows and linux. Not sure if this has been fixed by any future 3.x sdks.
What I want, is to move a text from right to left (like stock market prices) in a Dynamic Text Field of fixed width. That's all!It appears really easy, but I've googled the web for hours and found only highly comlex solutions with masks and things I don't understand (i am still a beginner with AS3) or solutions based upon EnterFrame action and I need my text to be indepedent upon EnterFrame action as it concernes many nested movie clips and animations.
I'm wondering if there's a way to have a text and use 2 different embed fonts.Basically, i have a text from a xml file and one textfield that I want to scroll but I want to use a different font for the title.I tried something like:
Having a bit of trouble getting embedded fonts to work. The inconsistency with this is driving me crazy. I've gotten this to work before but not since going to cs5.[code]...
I am having a major issue with a textfield. I have a dynamic text field which receives html so its htmlText I cant use the regular textFormat as the overrides the bold tags in the html. So I need to use css. Minor complication I have to do inline css as I cant load external data due to the project specs. Not a problem I have done inline css pretty easy. But they want a non web safe font. Again no prob I can embed fonts via the library. The problem is getting the css to use the embed font from the library. I have tried adding the font as a object to my code and then in the css referencing it via myfont.fontName, as a string etc.. 5
When I create a textbox by using textbox tool, I can embed the fonts and the Turkish characters with embed button (autofill). But when I create a text field by AS2.0, I can embed the font but text box shows only the English characters with my font.
i've tried a lot of things... but i just cant embed this text wich i load through php:<TEXTFORMAT LEADING="2"><P ALIGN="LEFT"><FONT FACE="_sans" SIZE="12" COLOR="#000000"LETTERSPACING="0" KERNING="0">Plaats uw tekst hier</FONT></P></TEXTFORMAT>i tried embedding italics, bold and regular in different textfields outside the work area... i thought that should do it... but it doesnt
I'm trying to embed fonts at runtime in actionscript and it somewhat works. I can embed fonts by either using the embed tag or by loading a font library asset with a linkage name and use it with a new TextField. However, a textfield that exists on a movie clip already does not have the embedded font and is missing characters.
A quick example in code (textInstance exists on the movieclip): var embeddedFonts = Font.enumerateFonts(); //Shows embedded font var textFormat:TextFormat = textInstance.getTextFormat(); textInstance.text = "Don't be lazy"; //missing characters
[Code].....
I want to embed the font at runtime and I'm loading multiple SWFs and I don't want to embed the font in each SWF.
My problem is quite simple to describe, in flex: 0.8 - 0.2 = 0.6000000000000001 I'm sure the first two members are 0.8 and 0.2 and are Number class, why would this happen?? And another thing, I cast the value from * type like this:
var value:*=0.8; var castValue:Number = Number(value);
But nothing more, if I trace value I get 0.8 not 0.800000000000001 or something.