2 error_reporting(E_ERROR | E_WARNING | E_PARSE
);
4 define('MOBILE_VERSION', true);
6 require_once "../../config.php";
7 require_once "functions.php";
8 require_once "../../functions.php";
10 require_once "../../sessions.php";
12 require_once "../../version.php";
13 require_once "../../db-prefs.php";
15 $link = db_connect(DB_HOST
, DB_USER
, DB_PASS
, DB_NAME
);
17 init_connection($link);
19 login_sequence($link, 2);
21 /* perform various redirect-needing subops */
23 $subop = db_escape_string($_GET["subop"]);
26 if ($subop == "tc" && !$go) {
28 $cat_id = db_escape_string($_GET["id"]);
29 toggle_collapse_cat($link, $cat_id);
31 header("Location: index.php");
35 $ts_id = db_escape_string($_GET["ts"]);
37 if ($go == "vf" && $ts_id) {
39 toggleMarked($link, $ts_id);
41 $query_string = preg_replace("/&ts=[0-9]*/", "", $_SERVER["QUERY_STRING"]);
42 header("Location: index.php?$query_string");
46 $tp_id = db_escape_string($_GET["tp"]);
48 if ($go == "vf" && $tp_id) {
50 togglePublished($link, $tp_id);
52 $query_string = preg_replace("/&tp=[0-9]*/", "", $_SERVER["QUERY_STRING"]);
53 header("Location: index.php?$query_string");
57 $sop = db_escape_string($_GET["sop"]);
61 $a_id = db_escape_string($_GET["id"]);
62 } elseif ($go == "vf") {
63 $a_id = db_escape_string($_GET["aid"]);
69 togglePublished($link, $a_id);
73 toggleMarked($link, $a_id);
77 markUnread($link, $a_id);
80 $query_string = str_replace("&sop=$sop", "", $_SERVER["QUERY_STRING"]);
81 header("Location: index.php?$query_string");
88 <title
>Tiny Tiny RSS
</title
>
89 <link rel
="stylesheet" type
="text/css" href
="mobile.css">
90 <meta http
-equiv
="Content-Type" content
="text/html; charset=utf-8">
91 <script type
="text/javascript" src
="mobile.js"></script
>
92 <?php
print_user_stylesheet($link) ?
>
94 <body id
="ttrssMobile">
99 render_feeds_list($link);
100 } else if ($go == "vf") {
101 render_headlines($link);
102 } else if ($go == "view") {
103 render_article($link);
104 } else if ($go == "sform") {
105 render_search_form($link, $_GET["aid"], $_GET["ic"]);
107 print __("Internal error: Function not implemented");