📄 item.php
字号:
<?php
/**************************************************************************************
Simple Library System
Copyright (C) 2002 John Mark Matthews
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
For further information, contact:
John Matthews
jmatthews@exostrategy.com
***************************************************************************************/
include("mainfile.inc");
include("header.inc");
include("footer.inc");
include("auth.inc");
reg('GET','item_id');
head();
OpenTable(0,3,3);
OpenLine();
OpenTable();
OpenRow();
OpenCell();
PrintItem($item_id);
CloseCell();
CloseRow();
CloseTable();
CloseLine();
OpenLine();
OpenTable(0,0,3);
OpenRow();
$r = mysql_query("select c.first_name, c.last_name, a.review, b.login, a.grade, a.create_td from tbl_review a, tbl_login b, tbl_person c where c.login_id=a.login_id and a.login_id=b.login_id and item_id=$item_id and trim(review)!='' order by a.create_td desc");
$i=1;
while($line = mysql_fetch_array($r)) {
if($i==1) {
echo Row(Cell(Bold("Reviews"),"class='header' colspan=4 width=650"));
}
$i++;
if(($i % 2)==0) {
$class='row_even';
}else{
$class='row_odd';
}
echo Row(
Cell("Date Posted:".Bold(format_mysql_datetime($line["create_td"]))).
Cell("Reviewed By:".Bold($line["first_name"]." ".$line["last_name"])), "class='$class'");
echo Row(
Cell("<br>".format_blob($line["review"]) , "colspan=4"), "class='$class'");
}
CloseTable();
CloseLine();
OpenLine();
OpenTable(0);
echo Row(Cell("<input type='button' value='Close' onClick='javascript:self.close()'>"));
CloseTable();
CloseLine();
CloseTable();
foot();
?>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -