_page_no(){if(event.keyCode==13) goto_page();if(event.keyCode<47||event.keyCode>57) event.returnValue=false;}</script>";
$result_str .= "<div id=\"pageArea\" class=\"pageArea\">\n第<span id=\"pageNumber\" class=\"pageNumber\">".$cur_page."/".$num_pages."</span>页";
if ( $cur_page <= 1 )
{
$result_str .= "<a href=\"javascript:;\" id=\"pageFirst\" class=\"pageFirstDisable\" title=\"首页\"></a>\r\n <a href=\"javascript:;\" id=\"pagePrevious\" class=\"pagePreviousDisable\" title=\"\"></a>";
}
else
{
$result_str .= "<a href=\"".$script_href.$hyphen.$var_name."=0&TOTAL_ITEMS=".$total_items."&PAGE_SIZE=".$page_size."\" id=\"pageFirst\" class=\"pageFirst\" title=\"首页\"></a>\r\n <a href=\"".$script_href.$hyphen.$var_name."=".( $current_start_item - $page_size )."&TOTAL_ITEMS=".$total_items."&PAGE_SIZE=".$page_size."\" id=\"pagePrevious\" class=\"pagePrevious\" title=\"\"></a>";
}
if ( $num_pages <= $cur_page )
{
$result_str .= "<a href=\"javascript:;\" id=\"pageNext\" class=\"pageNextDisable\" title=\"\"></a>\r\n <a href=\"javascript:;\" id=\"pageLast\" class=\"pageLastDisable\" title=\"末页\"></a>";
}
else
{
$result_str .= "<a href=\"".$script_href.$hyphen.$var_name."=".( $current_start_item + $page_size )."&TOTAL_ITEMS=".$total_items."&PAGE_SIZE=".$page_size."\" id=\"pageNext\" class=\"pageNext\" title=\"\"></a>\r\n <a href=\"".$script_href.$hyphen.$var_name."=".( 0 < $total_items % $page_size ? $total_items - $total_items % $page_size : $total_items - $page_size )."&TOTAL_ITEMS=".$total_items."&PAGE_SIZE=".$page_size."\" id=\"pageLast\" class=\"pageLast\" title=\"末页\"></a>";
}
$result_str .= "转到 第 <input type=\"text\" size=\"3\" class=\"SmallInput\" name=\"page_no\" id=\"page_no\" onkeypress=\"input_page_no()\" style=''text-align:center;''> 页 <a href=\"javascript:goto_page();\" id=\"pageGoto\" class=\"pageGoto\" title=\"转到\"></a>";
if ( $direct_print )
{
echo $result_str;
}
return $result_str;
}
function get_page_size( $MODULE, $DEFAULT_SIZE = 10 )
{
$PARA_ARRAY = get_sys_para( "PAGE_BAR_SIZE" );
$PAGE_SIZE_ARRAY = unserialize( $PARA_ARRAY[''PAGE_BAR_SIZE''] );
$PAGE_SIZE = intval( $PAGE_SIZE_ARRAY[$MODULE] );
$PAGE_SIZE = 0 < $PAGE_SIZE ? $PAGE_SIZE : $DEFAULT_SIZE;
return $PAGE_SIZE;
}
function send_mail( $FROM, $TO, $SUBJECT, $BODY, $SMTP_SERVER, $SMTP_USER, $SMTP_PASS, $SMTP_AUTH = TRUE, $FROM_NAME = "通达科技", $REPLY_TO = "", $CC = "", $BCC = "", $ATTACHMENT = "", $IS_HTML = TRUE, $SMTP_PORT = 25, $SMTPSecure = "" )
{
global $ATTACH_PATH2;
include_once( "inc/phpmailer/class.phpmailer.php" );
include_once( "inc/utility_file.php" );
$mail = new PHPMailer( );
$mail->SetLanguage( "zh" );
$mail->IsSMTP( );
$mail->Host = $SMTP_SERVER;
$mail->Port = $SMTP_PORT;
$mail->SMTPAuth = $SMTP_AUTH;
$mail->SMTPSecure = $SMTPSecure;
$mail->Username = $SMTP_USER;
$mail->Passwor