Example #1
0
def article(request, id):
    article = Article.get(id)
    
    if not article.content:
        target = ArticleParser.ArticleParser(article.url)
        target.process()
        logging.info('Loading new article from %s' % target.url)
        logging.info('Loading new article : %s' % target.title)
        
        article.content = target.get_content()
        article.put()
    
    return render_to_response('article.html', {'article':article})