aboutsummaryrefslogtreecommitdiffhomepage
path: root/inc/poche/Routing.class.php
diff options
context:
space:
mode:
Diffstat (limited to 'inc/poche/Routing.class.php')
-rwxr-xr-xinc/poche/Routing.class.php16
1 files changed, 13 insertions, 3 deletions
diff --git a/inc/poche/Routing.class.php b/inc/poche/Routing.class.php
index 6ae93d21..be06a433 100755
--- a/inc/poche/Routing.class.php
+++ b/inc/poche/Routing.class.php
@@ -102,7 +102,8 @@ class Routing
102 $this->wallabag->login($this->referer); 102 $this->wallabag->login($this->referer);
103 } elseif (isset($_GET['feed']) && isset($_GET['user_id'])) { 103 } elseif (isset($_GET['feed']) && isset($_GET['user_id'])) {
104 $tag_id = (isset($_GET['tag_id']) ? intval($_GET['tag_id']) : 0); 104 $tag_id = (isset($_GET['tag_id']) ? intval($_GET['tag_id']) : 0);
105 $this->wallabag->generateFeeds($_GET['token'], filter_var($_GET['user_id'],FILTER_SANITIZE_NUMBER_INT), $tag_id, $_GET['type']); 105 $limit = (isset($_GET['limit']) ? intval($_GET['limit']) : 0);
106 $this->wallabag->generateFeeds($_GET['token'], filter_var($_GET['user_id'],FILTER_SANITIZE_NUMBER_INT), $tag_id, $_GET['type'], $limit);
106 } 107 }
107 108
108 //allowed ONLY to logged in user 109 //allowed ONLY to logged in user
@@ -120,7 +121,16 @@ class Routing
120 $this->wallabag->deleteUser($_POST['password4deletinguser']); 121 $this->wallabag->deleteUser($_POST['password4deletinguser']);
121 } elseif (isset($_GET['epub'])) { 122 } elseif (isset($_GET['epub'])) {
122 $epub = new WallabagEpub($this->wallabag, $_GET['method'], $_GET['value']); 123 $epub = new WallabagEpub($this->wallabag, $_GET['method'], $_GET['value']);
123 $epub->run(); 124 $epub->prepareData();
125 $epub->produceEpub();
126 } elseif (isset($_GET['mobi'])) {
127 $mobi = new WallabagMobi($this->wallabag, $_GET['method'], $_GET['value']);
128 $mobi->prepareData();
129 $mobi->produceMobi();
130 } elseif (isset($_GET['pdf'])) {
131 $pdf = new WallabagPDF($this->wallabag, $_GET['method'], $_GET['value']);
132 $pdf->prepareData();
133 $pdf->producePDF();
124 } elseif (isset($_GET['import'])) { 134 } elseif (isset($_GET['import'])) {
125 $import = $this->wallabag->import(); 135 $import = $this->wallabag->import();
126 $tplVars = array_merge($this->vars, $import); 136 $tplVars = array_merge($this->vars, $import);
@@ -148,4 +158,4 @@ class Routing
148 { 158 {
149 echo $this->wallabag->tpl->render($file, $vars); 159 echo $this->wallabag->tpl->render($file, $vars);
150 } 160 }
151} \ No newline at end of file 161}