Skip to content

Instantly share code, notes, and snippets.

@Atheuz
Created November 12, 2012 21:44
Show Gist options
  • Save Atheuz/4062132 to your computer and use it in GitHub Desktop.
Save Atheuz/4062132 to your computer and use it in GitHub Desktop.
import lxml.etree
namespaces = {'dc': u"http://purl.org/dc/elements/1.1/"}
content = lxml.etree.fromstring(s)
content.xpath('//dc:description', namespaces=namespaces)[0].text
'EDITORIAL REVIEW:\n\nEx-Navy SEAL John Clark is the newly named head of Rainbow, an international task force dedicated to combating terrorism. In a trial by fire, he must stop a terrorist group of men and women so extreme that their success could literally mean the end of life on earth as we know it.'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment