Thread: [aKregator-devel] [Bug 100118] New: serendipity feed images not displayed
Brought to you by:
lippel
From: <kr...@ko...> - 2005-02-23 20:43:13
|
------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee. http://bugs.kde.org/show_bug.cgi?id=100118 Summary: serendipity feed images not displayed Product: akregator Version: unspecified Platform: unspecified OS/Version: Linux Status: UNCONFIRMED Severity: normal Priority: NOR Component: general AssignedTo: akregator-devel lists sourceforge net ReportedBy: kris koehntopp de Version: 1.0 beta10 (using KDE 3.4.0 Level "a" , SUSE 9.2 UNSUPPORTED) Compiler: gcc version 3.3.4 (pre 3.3.5 20040809) OS: Linux (i686) release 2.6.8-24.11-default I am using serendipity (http://www.s9y.org) as a blog system. My feed http://blog.koehntopp.de/rss.php?version=2.0 contains an image, but akregator only shows a generic image symbol on the right hand side of each article. This is true for all other s9y generated feeds. Images for other feeds, e.g. http://www.livejournal.com/users/jwz/data/rss are shown properly. What is wrong - is the image tag malformed or does akgregator have a problem with this image element? Does not work: <channel> <title>Die wunderbare Welt von Isotopp</title> <link>http://blog.koehntopp.de/</link> <description></description> <dc:language>de</dc:language> <admin:errorReportsTo rdf:resource="mailto:kris koehntopp de" /> <generator>Serendipity 0.8-alpha11 - http://www.s9y.org/</generator> <managingEditor>kris koehntopp de</managingEditor> <webMaster>kris koehntopp de</webMaster> <ttl>60</ttl> <image> <url>http://blog.koehntopp.de/webcam/kris.png</url> <title>RSS: Die wunderbare Welt von Isotopp - </title> <link>http://blog.koehntopp.de/</link> <width>129</width> <height>185</height> </image> ... Does work: <channel> <title>jwz</title> <link>http://www.livejournal.com/users/jwz/</link> <description>jwz - LiveJournal.com</description> <managingEditor>jwz jwz org</managingEditor> <lastBuildDate>Wed, 23 Feb 2005 10:29:51 GMT</lastBuildDate> <generator>LiveJournal / LiveJournal.com</generator> <image> <url>http://www.livejournal.com/userpic/5887295/515656</url> <title>jwz</title> <link>http://www.livejournal.com/users/jwz/</link> <width>83</width> <height>83</height> </image> ... |
From: Teemu R. <tp...@d5...> - 2005-02-24 20:18:13
|
------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee. http://bugs.kde.org/show_bug.cgi?id=100118 tpr d5k net changed: What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |NEW everconfirmed|0 |1 ------- Additional Comments From tpr d5k net 2005-02-24 21:17 ------- This is caused by the way the image urls are currently handled and not escaped before use. I just fixed this to my local copy, but can't commit yet since the cvs is frozen... |
From: Teemu R. <tp...@d5...> - 2005-02-26 22:17:14
|
------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee. http://bugs.kde.org/show_bug.cgi?id=100118 tpr d5k net changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED Resolution| |FIXED ------- Additional Comments From tpr d5k net 2005-02-26 23:17 ------- CVS commit by rytilahti: Umm, use KURL for url handling instead of QString... Will backport soon. BUGS:100118 M +11 -4 articleviewer.cpp 1.94 M +1 -1 articleviewer.h 1.35 --- kdepim/akregator/src/articleviewer.cpp #1.93:1.94 @ -59,5 +59,6 @ ArticleViewer::ArticleViewer(QWidget *pa connect(kapp, SIGNAL(kdisplayPaletteChanged()), this, SLOT(slotPaletteOrFontChanged()) ); connect(kapp, SIGNAL(kdisplayFontChanged()), this, SLOT(slotPaletteOrFontChanged()) ); - m_imageDir="file:"+KGlobal::dirs()->saveLocation("cache", "akregator/Media/"); + + m_imageDir.setPath(KGlobal::dirs()->saveLocation("cache", "akregator/Media/")); m_htmlFooter = "</body></html>"; } @ -218,5 +219,8 @ QString ArticleViewer::formatArticle(Fee { QString url=feed->xmlUrl(); - text += QString("<a href=\""+feed->htmlUrl()+"\"><img class=\"headimage\" src=\""+m_imageDir+url.replace("/", "_").replace(":", "_")+".png\"></a>\n"); + QString file = url.replace("/", "_").replace(":", "_"); + KURL u(m_imageDir); + u.setFileName(file); + text += QString("<a href=\"%1\"><img class=\"headimage\" src=\"%2.png\"></a>\n").arg(feed->htmlUrl()).arg(u.url()); } @ -349,5 +353,8 @ void ArticleViewer::showSummary(Feed *f) text += QString("<div class=\"body\">"); QString url=f->xmlUrl(); - text += QString("<a href=\""+f->htmlUrl()+"\"><img class=\"headimage\" src=\""+m_imageDir+url.replace("/", "_").replace(":", "_")+".png\"></a>\n"); + QString file = url.replace("/", "_").replace(":", "_"); + KURL u(m_imageDir); + u.setFileName(file); + text += QString("<a href=\"%1\"><img class=\"headimage\" src=\"%2.png\"></a>\n").arg(f->htmlUrl()).arg(u.url()); } else text += "<div class=\"body\">"; --- kdepim/akregator/src/articleviewer.h #1.34:1.35 @ -103,5 +103,5 @ namespace Akregator QString m_htmlFooter; QString m_currentText; - QString m_imageDir; + KURL m_imageDir; TreeNode* m_node; ArticleFilter m_textFilter; |
From: Teemu R. <tp...@d5...> - 2005-02-26 22:26:27
|
------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee. http://bugs.kde.org/show_bug.cgi?id=100118 ------- Additional Comments From tpr d5k net 2005-02-26 23:26 ------- CVS commit by rytilahti: backport CCBUGS:100118 M +11 -4 articleviewer.cpp 1.93.4.1 M +1 -1 articleviewer.h 1.34.6.1 --- kdepim/akregator/src/articleviewer.cpp #1.93:1.93.4.1 @ -59,5 +59,6 @ ArticleViewer::ArticleViewer(QWidget *pa connect(kapp, SIGNAL(kdisplayPaletteChanged()), this, SLOT(slotPaletteOrFontChanged()) ); connect(kapp, SIGNAL(kdisplayFontChanged()), this, SLOT(slotPaletteOrFontChanged()) ); - m_imageDir="file:"+KGlobal::dirs()->saveLocation("cache", "akregator/Media/"); + + m_imageDir.setPath(KGlobal::dirs()->saveLocation("cache", "akregator/Media/")); m_htmlFooter = "</body></html>"; } @ -218,5 +219,8 @ QString ArticleViewer::formatArticle(Fee { QString url=feed->xmlUrl(); - text += QString("<a href=\""+feed->htmlUrl()+"\"><img class=\"headimage\" src=\""+m_imageDir+url.replace("/", "_").replace(":", "_")+".png\"></a>\n"); + QString file = url.replace("/", "_").replace(":", "_"); + KURL u(m_imageDir); + u.setFileName(file); + text += QString("<a href=\"%1\"><img class=\"headimage\" src=\"%2.png\"></a>\n").arg(feed->htmlUrl()).arg(u.url()); } @ -349,5 +353,8 @ void ArticleViewer::showSummary(Feed *f) text += QString("<div class=\"body\">"); QString url=f->xmlUrl(); - text += QString("<a href=\""+f->htmlUrl()+"\"><img class=\"headimage\" src=\""+m_imageDir+url.replace("/", "_").replace(":", "_")+".png\"></a>\n"); + QString file = url.replace("/", "_").replace(":", "_"); + KURL u(m_imageDir); + u.setFileName(file); + text += QString("<a href=\"%1\"><img class=\"headimage\" src=\"%2.png\"></a>\n").arg(f->htmlUrl()).arg(u.url()); } else text += "<div class=\"body\">"; --- kdepim/akregator/src/articleviewer.h #1.34:1.34.6.1 @ -103,5 +103,5 @ namespace Akregator QString m_htmlFooter; QString m_currentText; - QString m_imageDir; + KURL m_imageDir; TreeNode* m_node; ArticleFilter m_textFilter; |