Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
297 views
in Technique[技术] by (71.8m points)

iphone - Readability in my application

I wonder how to open some article using 'reading view' of Readability - just like Tweetbot is doing it. But without sending article to my account and save to queue.

Displaying article using Readability like in Reeder is not so easy, right? I would have to write to company and ask them for access to their parser?

Maybe is there any other good way to parse articles using Readability. I have read something about javascript parser, but don't know too much.

Could you help me?

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

You can use Readability mobilizer for this. You will get a cleaned up version of any article, in the Readability styling:

http://www.readability.com/m?url=http://{URLOFTHEARTICLE}

Just prepare the URL and load it in your UIWebView. I'm escaping the parameter values. Here is how it looks in action:

http://www.readability.com/m?url=http%3A%2F%2Fwww.cnn.com%2F2013%2F01%2F11%2Fshowbiz%2Ftv%2Fgolden-globes-tv-vineyard%2Findex.html%3Fhpt%3Dhp_abar


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...