# String issue

**URL:** <https://forum.kirupa.com/t/string-issue/289151>\
**Category:** flash\
**Created:** [May 26, 2009, 11:04pm UTC](https://forum.kirupa.com/t/string-issue/289151 "2009-05-26T23:04:15Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![rondog](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/rondog/32/2478_2.png) [@rondog](https://forum.kirupa.com/u/rondog)\
**Post date:** [May 26, 2009, 11:04pm UTC](https://forum.kirupa.com/t/string-issue/289151/1 "2009-05-26T23:04:15Z")

</div>

So I am parsing some XML and at the end of each node there are some tags I cannot remove…example:

```auto

<items>
<description>
  <![CDATA[<P>Here is a description...</P>
    <P><!--FLASH--></P>
    <P>This course requires the latest FLASH Player &amp;nbsp;&amp;nbsp;&amp;nbsp;</P>
    <P></P>
    <P><STRONG>CAUTION: Prior to downloading the FLASH Player, deselect the GoogleToolbar option</STRONG><BR><BR><BR><BR></P>
    <P></P>]]>
</description>
<description>
  <![CDATA[Here is a description...
    <BR><!--FLASH-->
    <BR>This course requires the latest FLASH Player &amp;nbsp;&amp;nbsp;&amp;nbsp;
    <P><STRONG>CAUTION: Prior to downloading the FLASH Player, deselect the GoogleToolbar option.</STRONG></P>]]>
</description>
<items>

```

I know the formatting of this thing is not good, however, I am not in charge of generating it so I cannot edit it directly. I can only use it to read from…

Now my question is, the company that makes this file added a \<!–FLASH–\> tag so I can parse through the description node and break at the \<!–FLASH–\> tag however there is some \<BR\> and \<p\> tags that I cannot strip because they are not always the same. This in turn adds line breaks to some of my descriptions…I don’t want to completely strip all tags because a description could have a link break in the middle of the description.

I want to just remove the tags in front of the \<!–FLASH–\> tag. Can anybody think of a solution?
