|
-
[RESOLVED] Unwanted HTML Markup in Text Box Value
I've inherited a Flash MX 2004 document that has some text entry points that verify you've entered the right text before continuing or provide you a warning message and urge you to try hard. They're set up like so:
Code:
on (keypress "<Enter>")
{
if (titleInputText == "hoped-for text entry")
{
gotoAndPlay("someNamedTarget");
}
else
{
comment = "Hey--enter hoped-for text entry to continue!";
}
}
Some of them just weren't behaving at all correctly. With some handy-dandy trace() statements, I found that a few of them were returning values that included HTML formating of the text. Instead of getting
I was getting
Code:
<FONT = "Arial">something entered</FONT>
which is causing me all sorts of problems. How on earth can I turn off the HTML tags? Where did it come from?
(Why, yes, I do know just enough to get myself in trouble. Why do you ask?)
Any help would be greatly appreciated on this.
-
Try selecting the text box and and unselecting the "< >" button on the Properties panel. Assuming your users don't need to input HTML. If that doesn't work, give the textfield an instance name and get the value of instanceName.text.
-
Now, that's the part that's driving me crazy. Looking at the properties of the text box, the "<>" is deselected already! So where is the HTML coming from if not from there?
I'll try naming the thing and letting you know how it goes.
Thanks.
-
Well, the naming didn't work either.
So I removed the offending elements and remade them exactly as it looked like they had been, and now they work with both the variable value and the .text call.
Huh. Odd, but true.
Thanks for the help.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|