title: Scraping an html with Swift 4 in Xcode 9
body: <p>Ok I have a website I want to scrape for specific links.
  I already used URLSession to put all websites contents into a string.
  Now I have to get all Links into an array which have the following structure:</p>
  
  <p>"&lt;   a href="/thisIsAlwaysTheSame/ThisIsAUniqueNumber/ThisIsWhatIDontNeed..."</p>
  
  <p>So that I get an array: [href="/thisIsAlwaysTheSame/UniqueNumberA/, href="/thisIsAlwaysTheSame/UniqueNumberB, href="/thisIsAlwaysTheSame/UniqueNumberC, etc.]"
  There are many more links on the website, but I only need those which have this format.
  Optionally I would also be happy if I get only the UniqueNumbers into an array.</p>
  
  <p>I already asked this question on reddit, but didn't get sufficient answers:
  <a href="https://www.reddit.com/r/swift/comments/7256vi/scraping_an_html_with_swift_4_in_xcode_9/" rel="nofollow noreferrer">https://www.reddit.com/r/swift/comments/7256vi/scraping_an_html_with_swift_4_in_xcode_9/</a></p>
  
  <p>Here is what I know already from my research and the answers on reddit already:</p>
  
  <ul>
  <li><p>"Kanna" is suggested --> I can't get it running in Xcode 9 (I already opened an issue on GitHub)</p></li>
  <li><p>SwiftSoup could be an option --> Same problem like Kanna, can't get it running in Xcode 9 (I also opened an Issue on Github)</p></li>
  <li><p>I got the advice that I can solve my problem with the Swift string class reading up following link:  <a href="https://developer.apple.com/documentation/swift/string" rel="nofollow noreferrer">https://developer.apple.com/documentation/swift/string</a> --> I read it but don't really see how I can solve my problem with these methods. Perhaps I am missing something there?</p></li>
  </ul>
  
  <p>Any advice? Thanks for your help!</p>