]> git.wh0rd.org Git - tt-rss.git/commitdiff
present png star images for non-IE browsers
authorAndrew Dolgov <fox@bah.spb.su>
Thu, 23 Aug 2007 14:21:12 +0000 (15:21 +0100)
committerAndrew Dolgov <fox@bah.spb.su>
Thu, 23 Aug 2007 14:21:12 +0000 (15:21 +0100)
functions.php
images/mark_set.png [new file with mode: 0644]
images/mark_unset.png [new file with mode: 0644]

index 56b4a3c9a45413ded4e6e51635a3bfac22801115..3a7b4bf1464a5eba212b7c0787a7cde1a3a4c8d5 100644 (file)
 
                if ($num_starred > 0) $class .= "Unread";
 
+               $is_ie = (strpos($_SESSION["client.userAgent"], "MSIE") !== false);
+
+               if ($is_ie) {
+                       $mark_img_ext = "gif";
+               } else {
+                       $mark_img_ext = "png";
+               }
+
                printFeedEntry(-1, $class, __("Starred articles"), $num_starred, 
-                       "images/mark_set.gif", $link);
+                       "images/mark_set.$mark_img_ext", $link);
 
                $class = "virt";
 
                                } else {
                                        $is_unread = false;
                                }
-       
+
+                               $is_ie = (strpos($_SESSION["client.userAgent"], "MSIE") !== false);
+
+                               if ($is_ie) {
+                                       $mark_img_ext = "gif";
+                               } else {
+                                       $mark_img_ext = "png";
+                               }
+
                                if ($line["marked"] == "t" || $line["marked"] == "1") {
-                                       $marked_pic = "<img id=\"FMPIC-$id\" src=\"images/mark_set.gif\" 
+                                       $marked_pic = "<img id=\"FMPIC-$id\" src=\"images/mark_set.$mark_img_ext\" 
                                                class=\"markedPic\"
                                                alt=\"Unstar article\" onclick='javascript:tMark($id)'>";
                                } else {
-                                       $marked_pic = "<img id=\"FMPIC-$id\" src=\"images/mark_unset.gif\" 
+                                       $marked_pic = "<img id=\"FMPIC-$id\" src=\"images/mark_unset.$mark_img_ext\" 
                                                class=\"markedPic\"
                                                alt=\"Star article\" onclick='javascript:tMark($id)'>";
                                }
diff --git a/images/mark_set.png b/images/mark_set.png
new file mode 100644 (file)
index 0000000..b35655c
Binary files /dev/null and b/images/mark_set.png differ
diff --git a/images/mark_unset.png b/images/mark_unset.png
new file mode 100644 (file)
index 0000000..bf9059a
Binary files /dev/null and b/images/mark_unset.png differ