Hi,

What you can do is write a utility method and explicitly check the
occurrence of <a> and <i> tags.

If you encounter these days then don't replace them otherwise for all
occurrences of other characters(.*?","") replace them  in the result String.

Thanks,

Nirmal

On Mon, Jun 15, 2009 at 9:15 PM, vunet <vunet...@gmail.com> wrote:

>
> If this strips my HTML out of the string:
>
> str.replaceAll("<.*?>","");
>
> ...how can I strip everything excluding, say, A and I tags? Basically
> I want to keep <a> and <i> tags. Please suggest.
>
> >
>


-- 
                \\\///
              /         \
              | \\   // |
            ( | (.) (.) |)
----------o00o--(_)--o00o-----------------
Stand up,be bold,be strong.
Take the whole responsibility on
ur own shoulders and know that
U are the creator of ur own destiny.
------ooo0-------------------------------
    (   )     0ooo
     \ (      (   )
      \_)      ) /
              (_/

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Java 
EE (J2EE) Programming with Passion!" group.
To post to this group, send email to 
java-ee-j2ee-programming-with-passion@googlegroups.com
To unsubscribe from this group, send email to 
java-ee-j2ee-programming-with-passion+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/java-ee-j2ee-programming-with-passion?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to