Dynamic Text problem

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Shawn Northrop
    New Member
    • Jan 2007
    • 67

    #1

    Dynamic Text problem

    Hi,
    I am having trouble loading dynamic text with html content specifically
    <br>. If i have the rendered as html option checked the bold property of the font i initially set goes away and instead of making new line the <br> is replaced with br (no brackets). am i doing something wrong?

    heres the code:
    Code:
    popinfo = _root.txt_tour.show_mc.show_txt;
    
    showPop1_btn.onRollOver= function(){
    	popinfo.text = "Featuring Sarah Bettens, Christine Baze and Jesse Ciarmataro. <br> 630 N. High Street - 10pm - $12-$15<br> call: 614.930.2260 for tickets";	
    	showinfo();
    };
    showPop1_btn.onRollOut = function(){
    	show_mc._visible = false;
    };
    also the text has multiline option selected.
  • xNephilimx
    Recognized Expert New Member
    • Jun 2007
    • 213

    #2
    To properly pass html text to the textbox (having it marked to render as HTML), don't use the popinfo.text, that only passes normal text. You must use popinfo.htmlTex t, like this:

    [CODE=actionscri pt]
    popinfo.htmlTex t = "Featuring Sarah Bettens, Christine Baze and Jesse Ciarmataro. <br> 630 N. High Street - 10pm - $12-$15<br> call: 614.930.2260 for tickets";
    [/CODE]

    Anyway, I'm not sure how flash will handle the br tag, the Flash's html render capability is awfully limited and buggy. If it doesn't work well, try using \n instead of the br, just in case.

    Kind regards,
    The_Nephilim

    Originally posted by Shawn Northrop
    Hi,
    I am having trouble loading dynamic text with html content specifically
    <br>. If i have the rendered as html option checked the bold property of the font i initially set goes away and instead of making new line the <br> is replaced with br (no brackets). am i doing something wrong?

    heres the code:
    Code:
    popinfo = _root.txt_tour.show_mc.show_txt;
    
    showPop1_btn.onRollOver= function(){
    	popinfo.text = "Featuring Sarah Bettens, Christine Baze and Jesse Ciarmataro. <br> 630 N. High Street - 10pm - $12-$15<br> call: 614.930.2260 for tickets";	
    	showinfo();
    };
    showPop1_btn.onRollOut = function(){
    	show_mc._visible = false;
    };
    also the text has multiline option selected.

    Comment

    Working...