]> git.immae.eu Git - github/wallabag/wallabag.git/commitdiff
possibilité de désactiver la récupération des images d'un article
authornicosomb <nicolas@loeuillet.org>
Thu, 18 Apr 2013 07:43:08 +0000 (09:43 +0200)
committernicosomb <nicolas@loeuillet.org>
Thu, 18 Apr 2013 07:43:08 +0000 (09:43 +0200)
inc/config.php
inc/functions.php

index a7904def07d304065518af692bf4d910dd94ea2e..4db3cf40232c5ac2c91bac7cc36bc145fc7b0f46 100644 (file)
@@ -14,6 +14,7 @@ if (!is_dir('db/')) {
 
 define ('DB_PATH', 'sqlite:./db/poche.sqlite');
 define ('ABS_PATH', 'assets/');
+define ('DOWNLOAD_PICTURES', TRUE);
 
 include 'db.php';
 include 'functions.php';
index b7c7baffaf09cfe6b747276107a92c0172f6d651..f572d983f1356f93dfa15bbc13f5764becb7eaca 100644 (file)
@@ -112,7 +112,10 @@ function prepare_url($url, $id)
         {
             $content = $r->articleContent->innerHTML;
             $parametres['title'] = $r->articleTitle->innerHTML;
-            $parametres['content'] = filtre_picture($content, $url, $id);
+            if (DOWNLOAD_PICTURES) {
+                $content = filtre_picture($content, $url, $id);
+            }
+            $parametres['content'] = $content;
             return $parametres;
         }
     }