Changeset 1595 for branches/multiuser/admin
- Timestamp:
- 10/04/06 06:55:02 (2 years ago)
- Location:
- branches/multiuser/admin
- Files:
-
- 2 modified
-
channels.php (modified) (4 diffs)
-
items.php (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
branches/multiuser/admin/channels.php
r1530 r1595 98 98 $sql = "select " 99 99 ." c.id, c.title, c.url, c.siteurl, d.name, c.descr, c.parent, c.icon, c.mode, c.daterefreshed " 100 ." from " .getTable("channels") ." c, " . getTable("folders") ." d " 101 ." where d.id = c.parent "; 100 ." from " .getTable("channels") ." c " 101 ." inner join " . getTable("folders") ." d " 102 ." on d.id = c.parent "; 102 103 103 104 if (getConfig('rss.config.absoluteordering')) { … … 123 124 // get feed's tags 124 125 $tags = ""; 125 $sql2 = "select t.id, t.tag from " . getTable('tag') . " t, " 126 . getTable('metatag') . " m where t.id = m.tid " 127 . "and m.ttype = 'channel' and m.fid = $id"; 126 $sql2 = "select t.id, t.tag from " . getTable('tag') . " t " 127 . "inner join " . getTable('metatag') . " m " 128 . " on m.tid = t.id " 129 . "where m.ttype = 'channel' and m.fid = $id"; 128 130 $res2 = rss_query($sql2); 129 131 … … 747 749 748 750 function channel_edit_form($cid) { 749 $sql = "select id, title, url, siteurl, parent, descr, icon, mode from " .getTable("channels") ." where id=$cid";751 $sql = "select id, title, url, siteurl, parent, descr, icon, mode, daterefreshed, dateadded from " .getTable("channels") ." where id=$cid"; 750 752 $res = rss_query($sql); 751 list ($id, $title, $url, $siteurl, $parent, $descr, $icon, $mode) = rss_fetch_row($res);753 list ($id, $title, $url, $siteurl, $parent, $descr, $icon, $mode, $daterefreshed, $dateadded) = rss_fetch_row($res); 752 754 // get tags 753 $sql = "select t.tag from " . getTable('tag')." t, " . getTable('metatag') 754 . " m where t.id = m.tid and m.ttype = 'channel' and m.fid = $cid"; 755 $sql = "select t.tag from " . getTable('tag')." t " 756 . " inner join " . getTable('metatag') . " m " 757 . " on m.tid = t.id " 758 . "where m.ttype = 'channel' and m.fid = $cid"; 755 759 $res = rss_query($sql); 756 760 $tags = ""; … … 763 767 764 768 echo "<form method=\"post\" action=\"" .$_SERVER['PHP_SELF'] ."#fa$cid\" id=\"channeledit\">\n"; 765 echo "<fieldset id=\"channeleditfs\">" 766 ."<p>"; 769 echo "<fieldset id=\"channeleditfs\">"; 770 // Timestamps 771 if(!empty($daterefreshed)) { 772 echo "<p><label>" . LBL_ADDED . ": " . date("M-d-Y H:i", strtotime($dateadded)) . "</label></p>" 773 ."<p><label>" . LBL_LAST_UPDATE . ": ".date("M-d-Y H:i", strtotime($daterefreshed))."</label></p>\n"; 774 } else { 775 echo "<p><label>" . LBL_ADDED . ": " . date("M-d-Y H:i", strtotime($dateadded)) . "</label></p>" 776 ."<p><label>" . LBL_LAST_UPDATE . ": " . LBL_FOOTER_LAST_MODIF_NEVER . "</label></p>\n"; 777 } 767 778 // Item name 768 echo "< label for=\"c_name\">". LBL_ADMIN_CHANNEL_NAME ."</label>\n"779 echo "<p><label for=\"c_name\">". LBL_ADMIN_CHANNEL_NAME ."</label>\n" 769 780 ."<input type=\"text\" id=\"c_name\" name=\"c_name\" value=\"$title\" />" 770 781 ."<input type=\"hidden\" name=\"".CST_ADMIN_DOMAIN."\" value=\"". CST_ADMIN_DOMAIN_CHANNEL."\" />\n" -
branches/multiuser/admin/items.php
r1530 r1595 96 96 break; 97 97 } 98 $sql = " from ".getTable('item') ." i INNER JOIN " .getTable('channels') . " c ONc.id=i.cid "98 $sql = " from ".getTable('item') ." i inner join " .getTable('channels') . " c on c.id=i.cid " 99 99 ." where 1=1 "; 100 100 … … 131 131 } 132 132 133 $tsql = " select distinct fid from ". getTable('metatag') . " m, " 134 . getTable('tag') . " t" 135 ." where m.tid=t.id and t.tag in ('" 133 $tsql = " select distinct fid from ". getTable('metatag') . " m " 134 . " inner join " . getTable('tag') . " t" 135 . " on t.id = m.tid " 136 . " where t.tag in ('" 136 137 . implode("', '", $trimmed_exclude_tags) ."')"; 137 138 } … … 151 152 //delete the tags for these items 152 153 $sqlids = "select distinct i.id,i.cid " . $sql 153 . " and i.cid=c.idorder by i.cid, i.id desc";154 . " order by i.cid, i.id desc"; 154 155 155 156
