# Adding htmlstuff to sen.xml menu

**URL:** <https://forum.kirupa.com/t/adding-htmlstuff-to-sen-xml-menu/118179>\
**Category:** Uncategorized\
**Created:** [August 3, 2004, 1:00pm UTC](https://forum.kirupa.com/t/adding-htmlstuff-to-sen-xml-menu/118179 "2004-08-03T13:00:25Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![modulater](https://avatars.discourse-cdn.com/v4/letter/m/958977/32.png) [@modulater](https://forum.kirupa.com/u/modulater)\
**Post date:** [August 3, 2004, 1:00pm UTC](https://forum.kirupa.com/t/adding-htmlstuff-to-sen-xml-menu/118179/1 "2004-08-03T13:00:25Z")

</div>

Hi there,

Anyone can help me out on the following.In the xml dropdownmenu from senuclar(tutorial) you can load txt in a txtfield but how can I add breaks, url’s, bold, … to my txt.

In the .fla I have the following:

Actions.message = function(msg) {  
trace(msg);  
message\_txt.html = true;  
message\_txt.htmlText = msg;  
}

this is how the xml looks like:

\<menu name=“main nav”\>  
\<item name=“button1” action=“message” variables=" Here I have my txt "/\>  
\</menu\>

When I publish the .fla and add breaks in the xml file I’t just won’t show content.

Hope someone can help me out.Grtz

---

<div class="post-metadata">

**Author:** ![senocular](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/senocular/32/7217_2.png) [@senocular](https://forum.kirupa.com/u/senocular)\
**Post date:** [August 3, 2004, 1:09pm UTC](https://forum.kirupa.com/t/adding-htmlstuff-to-sen-xml-menu/118179/2 "2004-08-03T13:09:02Z")

</div>

XML attributes aren’t the best place for complex messages. You can add breaks using $#10; but you may be hard pressed for other things. You would instead want to use a Text node or maybe a CDATA section. This would require you to change the script a little bit to faciliate that, though.

\<item name=“button1” action=“message”\>  
\<![CDATA[ Here is all  
I wanted  
to say! ]]\>  
\</item\>

and instead of using the attributes.variables, youd have to use that node’s child element representing the CDATA block and snag that text.

---

<div class="post-metadata">

**Author:** ![modulater](https://avatars.discourse-cdn.com/v4/letter/m/958977/32.png) [@modulater](https://forum.kirupa.com/u/modulater)\
**Post date:** [August 3, 2004, 1:39pm UTC](https://forum.kirupa.com/t/adding-htmlstuff-to-sen-xml-menu/118179/3 "2004-08-03T13:39:59Z")

</div>

and instead of using the attributes.variables, youd have to use that node’s child element representing the CDATA block and snag that text.[/QUOTE]

Sorry but it’s all very new for me xml stuff. can you show me more what I have to change from your script to use this CDATA(script).

I have to make changes in these parts?Change to?

curr\_item.variables = curr\_node.attributes.variables;  
curr\_item.name.text = curr\_node.attributes.name;

Actions.message = function(msg) {  
trace(msg);  
message\_txt.html = true;  
message\_txt.htmlText = msg;  
}

Sorry all very new for me. Hope to hear from you again.

---

<div class="post-metadata">

**Author:** ![senocular](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/senocular/32/7217_2.png) [@senocular](https://forum.kirupa.com/u/senocular)\
**Post date:** [August 3, 2004, 2:26pm UTC](https://forum.kirupa.com/t/adding-htmlstuff-to-sen-xml-menu/118179/4 "2004-08-03T14:26:33Z")

</div>

I dont have time to go into detail with it now. Check out the XML stuff here on [kirupa.com](http://kirupa.com) for a head start.
