From d3fb010a8fd2862ed6619b9cbdefb22aa9bace9c Mon Sep 17 00:00:00 2001 From: "Michael D. Reiley" Date: Tue, 20 Sep 2011 12:49:07 -0700 Subject: New "Categories" theme, modifications for support. --- inc/functions.php | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'inc/functions.php') diff --git a/inc/functions.php b/inc/functions.php index a5c8a518..7ba2278b 100644 --- a/inc/functions.php +++ b/inc/functions.php @@ -228,6 +228,16 @@ } else return false; } + function boardTitle($uri) { + $query = prepare("SELECT `title` FROM `boards` WHERE `uri` = :uri LIMIT 1"); + $query->bindValue(':uri', $uri); + $query->execute() or error(db_error($query)); + + if($title = $query->fetch()) { + return $title['title']; + } else return false; + } + function purge($uri) { global $config, $debug; if(preg_match($config['url_match'], $config['root'])) { -- cgit v1.3