Skip to main content
edited tags
Link
Martin R
  • 541.4k
  • 98
  • 1.3k
  • 1.4k
edited tags
Link
Leo Dabus
  • 237.5k
  • 61
  • 512
  • 624
added 31 characters in body
Source Link
Zaid Syed
  • 793
  • 1
  • 6
  • 5

I'm working on a simple RSS Reader app as a beginner project in Xcode. I currently have it set up that it parses the feed, and places the title, pub date, description and content and displays it in a WebView.

I recently decided to show the description (or a truncated version of the content) in the TableView used to select a post. However, when doing so:

cell.textLabel?.text = item.title?.uppercaseString cell.detailTextLabel?.text = item.itemDescription //.itemDescription is a String 

It shows the raw HTML of the post.

I would like to know how to convert the HTML into plain text for just the TableView's detailed UILabel.

Thanks!

I'm working on a simple RSS Reader app as a beginner project in Xcode. I currently have it set up that it parses the feed, and places the title, pub date, description and content and displays it in a WebView.

I recently decided to show the description (or a truncated version of the content) in the TableView used to select a post. However, when doing so:

cell.textLabel?.text = item.title?.uppercaseString cell.detailTextLabel?.text = item.itemDescription 

It shows the raw HTML of the post.

I would like to know how to convert the HTML into plain text for just the TableView's detailed UILabel.

Thanks!

I'm working on a simple RSS Reader app as a beginner project in Xcode. I currently have it set up that it parses the feed, and places the title, pub date, description and content and displays it in a WebView.

I recently decided to show the description (or a truncated version of the content) in the TableView used to select a post. However, when doing so:

cell.textLabel?.text = item.title?.uppercaseString cell.detailTextLabel?.text = item.itemDescription //.itemDescription is a String 

It shows the raw HTML of the post.

I would like to know how to convert the HTML into plain text for just the TableView's detailed UILabel.

Thanks!

Source Link
Zaid Syed
  • 793
  • 1
  • 6
  • 5
Loading