1
0
mirror of https://github.com/moparisthebest/wallabag synced 2024-11-27 11:22:17 -05:00

[add] clean content articles in cron

This commit is contained in:
Nicolas Lœuillet 2014-03-07 14:49:36 +01:00
parent ded2c63312
commit 1ab567f6e3

View File

@ -1,5 +1,5 @@
<?php <?php
error_reporting(E_ALL);
include_once 'inc/poche/global.inc.php'; include_once 'inc/poche/global.inc.php';
include_once 'inc/poche/config.inc.php'; include_once 'inc/poche/config.inc.php';
@ -43,10 +43,10 @@ foreach ($items as $item) {
$body = $content['rss']['channel']['item']['description']; $body = $content['rss']['channel']['item']['description'];
// // clean content from prevent xss attack // // clean content from prevent xss attack
// $config = HTMLPurifier_Config::createDefault(); $config = HTMLPurifier_Config::createDefault();
// $purifier = new HTMLPurifier($config); $purifier = new HTMLPurifier($config);
// $title = $purifier->purify($title); $title = $purifier->purify($title);
// $body = $purifier->purify($body); $body = $purifier->purify($body);
$store->updateContentAndTitle($item['id'], $title, $body, $user_id); $store->updateContentAndTitle($item['id'], $title, $body, $user_id);