From 179380fe9957be7e747c33db8d4f3db87cdc5810 Mon Sep 17 00:00:00 2001 From: cedricbonhomme Date: Mon, 15 Feb 2010 11:45:38 +0100 Subject: Release 0.7. It is now possible to search for an article (description) with a query string. Regular expression will coming soon. --- pyAggr3g470r.py | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'pyAggr3g470r.py') diff --git a/pyAggr3g470r.py b/pyAggr3g470r.py index b26fa6cc..3c9a2be0 100644 --- a/pyAggr3g470r.py +++ b/pyAggr3g470r.py @@ -2,8 +2,8 @@ #-*- coding: utf-8 -*- __author__ = "Cedric Bonhomme" -__version__ = "$Revision: 0.6 $" -__date__ = "$Date: 2010/02/05 $" +__version__ = "$Revision: 0.7 $" +__date__ = "$Date: 2010/02/15 $" __copyright__ = "Copyright (c) 2010 Cedric Bonhomme" __license__ = "GPLv3" @@ -113,7 +113,8 @@ class Root: def q(self, v=None): """ - Search for a feed. + Search for a feed. Simply search for the string 'v' + in the description of the article. """ querystring = v.encode('utf-8') print querystring @@ -124,9 +125,7 @@ class Root: html += """

Articles containing the string %s


""" % (querystring,) for rss_feed_id in self.dic.keys(): - for article in self.dic[rss_feed_id][:10]: - description = article[4].encode('utf-8') if querystring in description: if article[7] == "0": -- cgit