]> git.wh0rd.org - tt-rss.git/commitdiff
get_user_theme_path()
authorAndrew Dolgov <fox@bah.spb.su>
Sat, 26 Nov 2005 06:40:47 +0000 (07:40 +0100)
committerAndrew Dolgov <fox@bah.spb.su>
Sat, 26 Nov 2005 06:40:47 +0000 (07:40 +0100)
functions.php

index de164c71d9adb7d967b5a82d8f3466ec261bcb21..89bc07d8e4bd75a28d4cf34d0f5a8ec4fa8af596 100644 (file)
                        return $str;
                }
        }
+
+       function get_user_theme_path($link) {
+               $result = db_query($link, "SELECT theme_path FROM ttrss_themes
+                       WHERE id = (SELECT theme_id FROM ttrss_users 
+                               WHERE id = " . $_SESSION["uid"] . ")");
+               if (db_num_rows($result) != 0) {
+                       return db_fetch_result($result, 0, "theme_path");
+               } else {
+                       return null;
+               }
+       }
 ?>