mirror of
https://github.com/xiaoyifang/goldendict-ng.git
synced 2024-11-27 23:34:06 +00:00
Fix Wikipedia images loading
This commit is contained in:
parent
34377a128a
commit
8c056589e9
|
@ -293,6 +293,9 @@ void MediaWikiArticleRequest::requestFinished( QNetworkReply * r )
|
||||||
// Replace the href="/foo/bar/Baz" to just href="Baz".
|
// Replace the href="/foo/bar/Baz" to just href="Baz".
|
||||||
articleString.replace( QRegExp( "<a\\shref=\"/([\\w\\.]*/)*" ), "<a href=\"" );
|
articleString.replace( QRegExp( "<a\\shref=\"/([\\w\\.]*/)*" ), "<a href=\"" );
|
||||||
|
|
||||||
|
// Add "http:" to image source urls
|
||||||
|
articleString.replace( " src=\"//", " src=\"http://" );
|
||||||
|
|
||||||
// In those strings, change any underscores to spaces
|
// In those strings, change any underscores to spaces
|
||||||
for( ; ; )
|
for( ; ; )
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in a new issue