Resolved Getting a text from html

Discussion in 'iOS Programming' started by erdinc27, Aug 2, 2016.

  1. erdinc27 macrumors regular

    Joined:
    Jul 20, 2011
    #1
    There is a service and it returns a keyword in an html body.

    How can i get that keyword from body ?

    Here is the link how html looks

    http://i.hizliresim.com/mLQk42.png
     
  2. erdinc27 thread starter macrumors regular

    Joined:
    Jul 20, 2011
    #2
    Code:
        
    NSURL *url = [NSURL URLWithString:@"theWebsiteURL"];
    NSString *webData= [NSString stringWithContentsOfURL:url encoding:NSUTF8StringEncoding error:nil];
    
    i could get by this way.
     
  3. PhoneyDeveloper macrumors 68030

    PhoneyDeveloper

    Joined:
    Sep 2, 2008
    #3
    Look into the HPPLE library on github and XPath queries to parse html and access individual bits of it.
     

Share This Page