aboutsummaryrefslogtreecommitdiffhomepage
path: root/inc/poche
diff options
context:
space:
mode:
authorNicolas LÅ“uillet <nicolas.loeuillet@gmail.com>2013-12-06 13:02:15 +0100
committerNicolas LÅ“uillet <nicolas.loeuillet@gmail.com>2013-12-06 13:02:15 +0100
commit5bea1a4d310e468d6ea1b71de36bdb4a53b8c57a (patch)
treeca708461916258425af39e1fd9f1b892e60f100a /inc/poche
parent9e7c840b186fb4ad2cd3768cec49ee348facf3da (diff)
downloadwallabag-5bea1a4d310e468d6ea1b71de36bdb4a53b8c57a.tar.gz
wallabag-5bea1a4d310e468d6ea1b71de36bdb4a53b8c57a.tar.zst
wallabag-5bea1a4d310e468d6ea1b71de36bdb4a53b8c57a.zip
[add] function to get tags by entry
Diffstat (limited to 'inc/poche')
-rw-r--r--inc/poche/Database.class.php11
1 files changed, 11 insertions, 0 deletions
diff --git a/inc/poche/Database.class.php b/inc/poche/Database.class.php
index c233eda1..86907e52 100644
--- a/inc/poche/Database.class.php
+++ b/inc/poche/Database.class.php
@@ -249,4 +249,15 @@ class Database {
249 public function getLastId($column = '') { 249 public function getLastId($column = '') {
250 return $this->getHandle()->lastInsertId($column); 250 return $this->getHandle()->lastInsertId($column);
251 } 251 }
252
253 public function retrieveTagsByEntry($entry_id) {
254 $sql =
255 "SELECT * FROM tags
256 LEFT JOIN tags_entries ON tags_entries.tag_id=tags.id
257 WHERE tags_entries.entry_id = ?";
258 $query = $this->executeQuery($sql, array($entry_id));
259 $tags = $query->fetchAll();
260
261 return $tags;
262 }
252} 263}