possibilité de désactiver la récupération des images d'un article

This commit is contained in:
nicosomb 2013-04-18 09:43:08 +02:00
parent 435bbd56ac
commit 64458521c3
2 changed files with 5 additions and 1 deletions

View 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';

View 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;
}
}