Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7903893
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 3, 20262026-06-03T09:51:50+00:00 2026-06-03T09:51:50+00:00

Hi every one I have a parsing RSS question. Current, I am able to

  • 0

Hi every one I have a parsing RSS question.

Current, I am able to parse the RSS XML on the news web, and display it in the UITableViewCell. I parse the description tag which is:

<description><![CDATA[ <a href="http://vnexpress.net/gl/xa-hoi/2012/05/thuy-dien-song-tranh-de-bi-lo-sut-dat-1/"><img src="http://vnexpress.net/Files/Subject/3b/bd/66/e0/sat-lo-dat-Song-Tranh-2.jpg"></a>this is new<BR />></description>

The problem now that I how can I just get out the text inside this tag? Currently it display everything inside the description tag, which is:

<![CDATA[ <a href="http://vnexpress.net/gl/xa-hoi/2012/05/thuy-dien-song-tranh-de-bi-lo-sut-dat-1/"><img src="http://vnexpress.net/Files/Subject/3b/bd/66/e0/sat-lo-dat-Song-Tranh-2.jpg"></a>this is new<BR />>

I just want the plain text to be displayed:

this is new

And I also wanna get the image in this description tag so I can display it:

<img src="http://vnexpress.net/Files/Subject/3b/bd/66/e0/sat-lo-dat-Song-Tranh-2.jpg">

. Please tell me how? Thanks in advance.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-03T09:51:51+00:00Added an answer on June 3, 2026 at 9:51 am

    I had to do this before. so I will paste the code I used here.

    - (NSString *)removeHTMLTags:(NSString *)str
    {   
    NSMutableString *temp_str = [[NSMutableString alloc] initWithString:str];
    NSRange openTag = [temp_str rangeOfString:@"<"];
    NSRange closeTag = [temp_str rangeOfString:@">"];
    
    while (openTag.length > 0) {
        NSRange range;
        range.location = openTag.location;
        range.length = (closeTag.location - openTag.location) + 1;
        [temp_str setString:[temp_str stringByReplacingCharactersInRange:range withString:@""]];
    
        openTag = [temp_str rangeOfString:@"<"];
        closeTag = [temp_str rangeOfString:@">"];
    }
    
    [temp_str replaceOccurrencesOfString:@"&Auml;" withString:@"Ä" options:NSLiteralSearch range:NSMakeRange(0, [temp_str length])];
    [temp_str replaceOccurrencesOfString:@"&Aring;" withString:@"Å" options:NSLiteralSearch range:NSMakeRange(0, [temp_str length])];
    [temp_str replaceOccurrencesOfString:@"&AElig;" withString:@"Æ" options:NSLiteralSearch range:NSMakeRange(0, [temp_str length])];
    
    
    while ([temp_str rangeOfString:@"  "].location != NSNotFound) {
        [temp_str replaceOccurrencesOfString:@"  " withString:@" " options:NSLiteralSearch range:NSMakeRange(0, [temp_str length])];
    }
    
    while ([temp_str rangeOfString:@" ."].location != NSNotFound) {
        [temp_str replaceOccurrencesOfString:@" ." withString:@"." options:NSLiteralSearch range:NSMakeRange(0, [temp_str length])];
    }
    
    while ([temp_str rangeOfString:@" ,"].location != NSNotFound) {
        [temp_str replaceOccurrencesOfString:@" ," withString:@"," options:NSLiteralSearch range:NSMakeRange(0, [temp_str length])];
    }
    
    while ([temp_str rangeOfString:@" ;"].location != NSNotFound) {
        [temp_str replaceOccurrencesOfString:@" ;" withString:@";" options:NSLiteralSearch range:NSMakeRange(0, [temp_str length])];
    }
    
    
    return temp_str;
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

to every one, i am doing xml parsing and i am getting two text
Hi every one I have these classe @Entity @Table(name = login, uniqueConstraints={@UniqueConstraint(columnNames={username_fk})}) public class
Hello every one I have wrote a simple code in html5 in which I
Hai every one I am developing an windows application in which i have to
I am writing my own blog (every one should, it's good experience). I have
I have a page with many tooltips. I want to show/hide every one seperatly
I have one particular FLA that is crashing every time I try to compile
I have one r function i want to run it automatically(scheduling) after every predefined
I have only one class with many instances. Every instance is observer of couple
Lets say we have an average of one page fault every 20,000,000 instructions, a

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.