📄 content_250.php
字号:
<?php
$paraarray = getindexpara( $block_id );
$rownum = $paraarray['block_row'];
$query = "select SID, CREATOR,Name, Active, StartDate, EndDate, (now() > EndDate) as Expired from phpqsurvey where Active='y' order by SID LIMIT 0,{$rownum}";
$cursor = exequery( $connection, $query );
$surveycount = 0;
while ( $row = mysql_fetch_array( $cursor ) )
{
++$surveycount;
$sid = $row['SID'];
$name = $row['Name'];
$active = $row['Active'];
$startdate = $row['StartDate'];
$enddate = $row['EndDate'];
$creator = $row['CREATOR'];
$startdate = explode( " ", $startdate );
$edate = explode( " ", $enddate );
$activeimg = "<img src=\"/images/littlegif/news_bullet.gif\" alt=\"生效\">";
$query2 = "select count(SID) from phpquser where SID=".$sid;
$cursor2 = exequery( $connection, $query2 );
$row2 = mysql_fetch_array( $cursor2 );
$now = date( "YmdHis" );
$ed = str_replace( " ", "", $edate );
$ed = str_replace( "-", "", $edate );
$ed = str_replace( ":", "", $edate );
if ( $row['Expired'] && substr( $enddate, 0, 10 ) != "0000-00-00" )
{
continue;
}
else
{
if ( $now < $ed )
{
echo "<div class=\"linkdiv\">";
echo $activeimg;
echo "\t\t\t<a href=\"#\" onclick=\"openWindows('/general/vote/fillsurvey.php?sid=";
echo $sid;
echo "')\" class=\"link\" >";
echo substrgb( $name, $paraarray['subject_length'], "..." );
echo "</a>\r\n\t\t\t";
if ( $active == "y" )
{
echo "(<a href=\"#\" onclick=\"openWindows('/general/vote/stats.php?sid=".$sid."&st=a&vw=a&fa=1&view=1')\">已提交".$row2[0]."份</a>) ";
echo "<span style=\"font-size:9px;color:#999999;\">".$startdate[0]." 至 ".$edate[0]."</span>";
}
if ( $paraarray['is_show_creator'] == 1 )
{
$user_name = getusername( $creator );
}
echo " <span class =\"linkgray\">{$user_name}</span>";
}
echo "</div>";
}
if ( $surveycount == 0 )
{
echo $nothindata;
}
}
echo "<div align=\"right\" style=\"padding:2px;font-size:12px;\"><a href=\"/general/vote/admin/surveyresult.php\">更多</a></div>\r\n";
?>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -