Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- from Products.CMFCore.utils import getToolByName
- catalog = getToolByName(context, 'portal_catalog')
- results = catalog(portal_type='checkorphan.news')
- for brain in results:
- newsObj=brain.getObject()
- print "Id: "+ str(newsObj.intid)
- print "Id: "+ newsObj.id
- print "Title: "+ newsObj.title
- print "Category:"+ newsObj.category
- print "Source Title: " + str(newsObj.source_title)
- print "Source URL: " + str(newsObj.source_url)
- print "Author Name: "+ str(newsObj.author_name)
- print "Author Email: "+ str(newsObj.author_email)
- print "Published At: "+ str(newsObj.publish_at)
- print "Timezone: "+ str(newsObj.timezone)
- print newsObj.body.raw #THIS LINE CAUSES INSUFFICIENT PRIVILEVGE
- return printed
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement