I have a string containing some html-code...Lets say it looks like this:
String htmlString = "<h1>This is a header</h1>Some description-text goes here. <img src='image.jpg' alt='My image' /><b>Here is a bold string</b>.";
Now I want to extract only the text from it, no tags etc should be included in my final string....Whats the best way to accomplish this?
I want a final string like: myFinalString = "This is a header. Some description-text goes here. Here is a bold text";
Since the content of the htmlString can vary I cant use the replace()-method because I dont know what kind of tags that is included in the string.
...
Go to the complete details ...