本文整理汇总了PHP中returnsystemlang函数的典型用法代码示例。如果您正苦于以下问题:PHP returnsystemlang函数的具体用法?PHP returnsystemlang怎么用?PHP returnsystemlang使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了returnsystemlang函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: newai_list_one
function newai_list_one()
{
global $db, $common_html, $tablename_one, $tablename_two, $link;
global $html_etc_one, $html_etc_two, $columns_one, $columns_two;
global $tablename, $SYTEM_CONFIG_TABLE;
global $SUNSHINE_USER_NAME_VAR, $SUNSHINE_USER_ID_VAR, $_SESSION;
$USER_NAME = $_SESSION[$SUNSHINE_USER_NAME_VAR];
print "<SCRIPT language=JavaScript>\n\tfunction clickMenu(url){\n\tparent.main_body.location=url;\n\t}\n\t</SCRIPT>\n\t";
$one_array = explode(':', $tablename_one);
//print_R($one_array);
$link_array = explode(':', $link);
//print_R($link_array);
$columns = returntablecolumn($tablename);
$columns_one = returntablecolumn($one_array[0]);
$html_etc_one = returnsystemlang($one_array[0], $SYTEM_CONFIG_TABLE);
switch ($db->databaseType) {
case 'mysql':
switch ($one_array[3]) {
case 'name':
$sql_one = "select " . $columns_one[(string) $one_array[1]] . "," . $columns_one[(string) $one_array[2]] . " from " . $one_array[0] . " where " . $columns_one[(string) $one_array[4]] . "='" . $USER_NAME . "'";
break;
case 'id':
$sql_one = "select " . $columns_one[(string) $one_array[1]] . "," . $columns_one[(string) $one_array[2]] . " from " . $one_array[0] . "";
break;
default:
$sql_one = "select " . $columns_one[(string) $one_array[1]] . "," . $columns_one[(string) $one_array[2]] . " from " . $one_array[0] . "";
break;
}
break;
case 'mssql':
switch ($one_array[3]) {
case 'name':
$sql_one = "select [" . $columns_one[(string) $one_array[1]] . "],[" . $columns_one[(string) $one_array[2]] . "] from [" . $one_array[0] . "] where [" . $columns_one[(string) $one_array[4]] . "]='" . $USER_NAME . "'";
break;
case 'id':
$sql_one = "select [" . $columns_one[(string) $one_array[1]] . "],[" . $columns_one[(string) $one_array[2]] . "] from [" . $one_array[0] . "]";
break;
default:
$sql_one = "select [" . $columns_one[(string) $one_array[1]] . "],[" . $columns_one[(string) $one_array[2]] . "] from [" . $one_array[0] . "]";
break;
}
break;
}
//print $sql_one;
$rs_one = $db->CacheExecute(150, $sql_one);
if ($rs_one->RecordCount() == 0) {
print_infor($common_html['common_html']['norecord'], 'trip');
exit;
}
while (!$rs_one->EOF) {
if (StrLen($link_array[3]) > 2) {
$LinkIndexName = (string) $link_array[3];
} else {
$LinkIndexName = $columns[(string) $link_array[3]];
}
$url = $link_array[0] . "?" . $link_array[1] . "=" . $link_array[2] . "&" . $LinkIndexName . "=" . $rs_one->fields[(string) $columns_one[(string) $one_array[1]]];
print "\n\t<TABLE class=small cellSpacing=1 cellPadding=0 width='100%' align=center bgColor=#000000 border=0>\n\t<TBODY>\n\t<TR class=TableContent title='' style='CURSOR: hand'\t onclick=clickMenu('{$url}')>\n\t<TD noWrap align=middle><table class=small cellPadding=3 align=center width=100% border=0 onmouseover=bgColor='#ffffff' onmouseout=bgColor='#d3e5fa'>\n\t<Tr><td align=middle><B>" . $rs_one->fields[(string) $columns_one[(string) $one_array[2]]] . "</B></TD></TR>\n\t</table></TD></TR>\n\t</TBODY></TABLE>\n";
$rs_one->MoveNext();
}
}
示例2: newai_list_two
function newai_list_two()
{
global $db, $common_html, $tablename_one, $tablename_two, $link;
global $html_etc_one, $html_etc_two, $columns_one, $columns_two;
global $tablename, $SYTEM_CONFIG_TABLE;
print "<SCRIPT language=JavaScript>\n\tfunction clickMenu(ID){ \n\t targetelement=document.all(ID);\n\tif (targetelement.style.display=='none')\n\t\t\ttargetelement.style.display='';\n\telse\n\t targetelement.style.display='none';\n\t }\n\t</SCRIPT>\n\t";
$one_array = explode(':', $tablename_one);
$two_array = explode(':', $tablename_two);
$link_array = explode(':', $link);
$columns = returntablecolumn($tablename);
$columns_one = returntablecolumn($one_array[0]);
$html_etc_one = returnsystemlang($one_array[0], $SYTEM_CONFIG_TABLE);
$columns_two = returntablecolumn($two_array[0]);
$html_etc_two = returnsystemlang($two_array[0], $SYTEM_CONFIG_TABLE);
$sql_one = "select " . $columns_one[(string) $one_array[1]] . "," . $columns_one[(string) $one_array[2]] . " from " . $one_array[0] . "";
$rs_one = $db->Execute($sql_one);
$Number = $rs_one->RecordCount();
if ($Number == 0) {
print_infor($common_html['common_html']['norecord'], 'trip');
exit;
}
while (!$rs_one->EOF) {
print "\n\t<TABLE class=small cellSpacing=1 cellPadding=0 width='100%' align=center bgColor=#000000 border=0>\n\t<TBODY>\n\t<TR bgColor='#d3e5fa' title='' style='CURSOR: hand'\t onclick=clickMenu('" . $rs_one->fields[(string) $columns_one[(string) $one_array[1]]] . "')>\n\t<TD noWrap align=middle><table class=small cellPadding=3 align=center width=100% border=0 onmouseover=bgColor='#ffffff' onmouseout=bgColor='#d3e5fa'>\n\t<Tr><td align=middle><B>" . $rs_one->fields[(string) $columns_one[(string) $one_array[2]]] . "</B></TD></TR>\n\t</table></TD></TR>\n\t</TBODY></TABLE>\n";
$one_id = $rs_one->fields[(string) $columns_one[(string) $one_array[1]]];
$sql_two = "select " . $columns_two[(string) $two_array[1]] . "," . $columns_two[(string) $two_array[2]] . " from " . $two_array[0] . " where " . $columns_two[(string) $two_array[3]] . "='{$one_id}'";
$rs_two = $db->Execute($sql_two);
//print $sql_two;//exit;
print "\n\t<TABLE class=small id={$one_id} style='DISPLAY: none'\n\tcellSpacing=1 cellPadding=0 width='100%' bgColor=#000000 border=0>\n\t<TBODY>\n";
while (!$rs_two->EOF) {
$two_id = $rs_two->fields[(string) $columns_two[(string) $two_array[1]]];
$two_name = $rs_two->fields[(string) $columns_two[(string) $two_array[2]]];
print "<TR class=TableData align=middle height=20>\n\t<TD noWrap><A href='" . $link_array[0] . "?" . $link_array[1] . "=" . $link_array[2] . "&" . $columns[(string) $link_array[3]] . "={$two_id}&" . $columns_one[(string) $one_array[1]] . "={$one_id}' target=\"main_body\">" . $two_name . "</A>\n\t</TD></TR>\n";
$rs_two->MoveNext();
}
print "</TBODY></TABLE>\n";
$rs_one->MoveNext();
}
}
示例3: newaiCharts
function newaiCharts()
{
global $html_etc, $tablename, $common_html, $custom_type;
global $db, $return_sql_line, $columns;
global $_POST, $_GET, $returnmodel, $primarykey_index;
global $action_submit, $merge, $form_attribute;
global $tabletitle;
global $showlistfieldlist, $showlistfieldfilter, $showlistfieldtype;
$showlistfieldlistArray = explode(',', $showlistfieldlist);
$showlistfieldfilterArray = explode(',', $showlistfieldfilter);
$showlistfieldtypeArray = explode(',', $showlistfieldtype);
//获取系统显示的色彩信息
$ColorArray = returnColorArray();
//获取系统求和字段信息
global $sum_index, $UserUnitFunctionIndex;
if ($sum_index != "") {
$sum_sql_index = " ,sum({$sum_index}) as sum ";
} else {
$sum_sql_index = "";
}
//报表统计主体部分开始
for ($k = 0; $k < sizeof($showlistfieldlistArray); $k++) {
$fieldIndex = $showlistfieldlistArray[$k];
$fieldName = $columns[$fieldIndex];
$fieldText = $html_etc[$tablename][$fieldName];
$mode = $showlistfieldfilterArray[$k];
$modeArray = explode(':', $mode);
//print_R($modeArray);
$modeIndex = $modeArray[0];
$Mode = "";
switch ($modeIndex) {
case '':
break;
case 'tablefilter':
case 'tablefiltercolor':
case 'radiofilter':
case 'radiofiltercolor':
if ($modeArray[1] == "month" && $modeArray[2] == "") {
$Mode = "Month";
$SQL = "select Date_Format({$fieldName},'%c') AS {$fieldName},Sum({$sum_index}) as sum,Count({$fieldName}) as num from {$tablename} group by {$fieldName}";
} else {
if ($modeArray[1] == "year" && $modeArray[2] == "") {
$Mode = "Year";
$SQL = "select Date_Format({$fieldName},'%Y') AS {$fieldName},Sum({$sum_index}) as sum,Count({$fieldName}) as num from {$tablename} group by {$fieldName}";
} else {
$Mode = "";
$SQL = "select {$fieldName},Count({$fieldName}) as num {$sum_sql_index} from {$tablename} group by {$fieldName}";
}
}
$rs = $db->CacheExecute(150, $SQL);
$rs_array = $rs->GetArray();
//print_R($rs_array);
//父表结构部分
$tablenameIndex = $modeArray[1];
$ColumnsIndex = returntablecolumn($tablenameIndex);
$html_etcIndex = returnsystemlang($tablenameIndex, $tablenameIndex);
$WhatIndex = $ColumnsIndex[(string) $modeArray[2]];
$ReturnIndex = $ColumnsIndex[(string) $modeArray[3]];
//本表操作部分--数据处理部分 --形成FLASH要处理的数据类型
$TotalNumberIndex = 0;
$TotalSumIndex = 0;
$Array = array();
for ($i = 0; $i < sizeof($rs_array); $i++) {
$ResultNumber = $rs_array[$i]['num'];
$ResultSum = $rs_array[$i]['sum'];
$ResultFieldCode = $rs_array[$i][$fieldName];
switch ($Mode) {
case 'Month':
$ResultFieldName = $ResultFieldCode . "" . $common_html['common_html']['month'];
break;
case 'Year':
$ResultFieldName = $ResultFieldCode . "" . $common_html['common_html']['year'];
break;
default:
$ResultFieldName = returntablefield($tablenameIndex, $WhatIndex, $ResultFieldCode, $ReturnIndex);
if ($ResultFieldName == "") {
$ResultFieldName = $ResultFieldCode;
}
break;
}
$TotalNumberIndex += $ResultNumber;
$TotalSumIndex += $ResultSum;
$Array_Statistic_Value = $sum_index != "" ? $ResultSum : $ResultNumber;
$Array['XData'][$i]['Name'] = $ResultFieldName;
$Array['XData'][$i]['Value'] = $Array_Statistic_Value;
$Array['XData'][$i]['Dir'] = $ResultFieldName;
$Array['XData'][$i]['AltText'] = $ResultFieldName;
//$Array['XData'][$i]['Url'] = "?action=init_customer&$fieldName=$ResultFieldCode";
$ColorArray[$i] == "" ? $ColorArray[$i] = "0xCC0000" : '';
$Array['XData'][$i]['Color'] = $ColorArray[$i];
$Array['Dir'][$i]['Name'] = $ResultFieldName;
$Array['Dir'][$i]['Color'] = $ColorArray[$i];
$Array['YData']['AltText'] = "移动查看详细信息";
$Array['YData']['Value'] < $Array_Statistic_Value ? $Array['YData']['Value'] = $Array_Statistic_Value : '';
}
$Array['title'] = $html_etc[$tablename][$tabletitle] . "[" . $html_etc[$tablename][$fieldName] . "]";
$array_graphInfo = $Array['title'] . "[" . date("Y-m-d H:i:s") . "] " . $common_html['common_html']['totalrecords'] . ": " . $TotalNumberIndex;
if ($sum_index != "") {
$array_graphInfo .= " " . $common_html['common_html']['allnumbers'] . ": " . $TotalSumIndex . " " . $UserUnitFunctionIndex . "\n";
}
//.........这里部分代码省略.........
示例4: newai_tree
newai_tree();
break;
case 'framework':
$tablename = $file_ini[$action]['tablename'];
$SYTEM_CONFIG_TABLE != "" ? $tablename = $SYTEM_CONFIG_TABLE : '';
$columns = returntablecolumn($tablename);
$html_etc = returnsystemlang($tablename, $SYTEM_CONFIG_TABLE);
$menu_top = $file_ini[$action]['menu_top'];
$primary = $file_ini[$action]['primary'];
project_framework($mode = 'project_framework');
break;
case 'menutop':
$tablename = $file_ini[$action]['tablename'];
$SYTEM_CONFIG_TABLE != "" ? $tablename = $SYTEM_CONFIG_TABLE : '';
$columns = returntablecolumn($tablename);
$html_etc = returnsystemlang($tablename, $SYTEM_CONFIG_TABLE);
$menu_top = $file_ini[$action]['menu_top'];
$primary = $file_ini[$action]['primary'];
project_framework($mode = 'project_fw_menu');
break;
}
$ExecTimeEnd = getmicrotime();
$ExecTime = $ExecTimeEnd - $ExecTimeBegin;
//print substr($ExecTime,0,8)." S";
$PHP_SELF_ARRAY = explode('/', $_SERVER['PHP_SELF']);
$PHP_SELF_TEXT = array_pop($PHP_SELF_ARRAY);
//print "<a href='StudentFileNew.php?dir=.&editfile=$PHP_SELF_TEXT&n=1' class=OrgAdd target=_blank>$PHP_SELF_TEXT</a>";
//注册提示
@(require_once "lib/version.php");
//定义显示文本
$PHP_SELF_ARRAY = explode('/', $_SERVER['PHP_SELF']);
示例5: print_select_menu_product
function print_select_menu_product($showtext, $showFieldName, $showFieldID, $showtext2, $showFieldName2, $showFieldValue, $tableName, $SelectFieldName, $SelectFieldname2, $colspan = 1)
{
global $db;
$sql = "select {$showFieldName},{$showFieldID},{$showFieldName2} from {$tableName} order by {$showFieldName}";
//print $sql;//exit;
$rst = $db->Execute($sql);
print "<SCRIPT language=JavaScript>\n";
//-----data
print "var onecount;\n";
print "onecount=0;\n";
print "subcat = new Array();\n";
$i = 0;
while (!$rst->EOF) {
print "subcat[{$i}] = new Array(\"" . $rst->fields[$showFieldName] . "\",\"" . $rst->fields[$showFieldID] . "\",\"" . $rst->fields[$showFieldName2] . "\");\n";
$i++;
$rst->MoveNext();
}
print "onecount={$i};\n";
//----deal_data_begin
print " function changelocation(locationid)\n";
print " {\n";
print " document.form1." . $SelectFieldname2 . ".length = 0; \n";
print " var locationid=locationid;\n";
print " var i;\n";
print " for (i=0;i<onecount;i++)\n";
print " {\n";
print " if (subcat[i][1] == locationid)\n";
print " { \n";
print " document.form1." . $SelectFieldname2 . ".value = subcat[i][2];\n";
print " } \n";
print " }\n";
print " } \n";
print "</SCRIPT>\n";
//-----deal_data_end
$html_etc_where_table = returnsystemlang($where_table);
$sql = "select {$showFieldName},{$showFieldID},{$showFieldName2} from {$tableName} order by {$showFieldName}";
$rse = $db->Execute($sql);
print "<TR><TD class=TableData noWrap>" . $showtext . "</TD><TD class=TableData noWrap>\n";
print "<SELECT id={$showFieldName} onkeydown=\"if(event.keyCode==13)event.keyCode=9\" class=\"SmallSelect\" onchange=changelocation(document.form1.{$showFieldName}.options[document.form1.{$showFieldName}.selectedIndex].value) \n";
print "size=1 name={$SelectFieldName}>\n";
$TestSelect = false;
while (!$rse->EOF) {
if ($rse->fields[$showFieldID] == $showFieldValue) {
$selected = 'selected';
$TestSelect = true;
$ValueTextField = $rse->fields[$showFieldName2];
} else {
$selected = '';
}
print "<OPTION value=\"" . $rse->fields[$showFieldID] . "\" {$selected}>" . $rse->fields[$showFieldName] . "</OPTION>\n";
$rse->MoveNext();
}
if (!$TestSelect) {
print "<OPTION value=\"\" selected>=========</OPTION>\n";
}
print "</SELECT> </TD></TR>\n";
print "<TR><TD class=TableData noWrap width=20%>" . $showtext2 . "</TD><TD class=TableData noWrap>\n";
$ValueTextField != "" ? '' : ($ValueTextField = '=========');
print "<INPUT class=SmallStatic maxLength=20 name=" . $SelectFieldname2 . " readonly value=\"" . $ValueTextField . "\" onkeydown=\"if(event.keyCode==13)event.keyCode=9\">";
print " </TD></TR>\n";
}
示例6: newai_dataline
function newai_dataline($modulename, $functionname = "dataline_view")
{
global $SUNSHINE_USER_NAME_VAR;
global $SUNSHINE_USER_ID_VAR;
global $_SESSION;
global $common_html;
global $db;
global $file_ini;
global $array_index;
global $SUNSHINE_USER_DEPT_VAR;
$USER_ID = $_SESSION[$SUNSHINE_USER_NAME_VAR];
$tablename = $file_ini[$modulename]['tablename'];
$primarykey = $file_ini[$modulename]['primarykey'];
$primaryname = $file_ini[$modulename]['primaryname'];
$date = $file_ini[$modulename]['date'];
$link = $file_ini[$modulename]['link'];
$width = $file_ini[$modulename]['width'];
$reader = $file_ini[$modulename]['reader'];
$format = $file_ini[$modulename]['format'];
$hidden_field = $file_ini[$modulename]['hidden_field'];
$columns = returntablecolumn($tablename);
$html_etc = returnsystemlang($tablename);
$primarykey_index = $columns[$primarykey];
$primaryname_index = $columns[$primaryname];
$date_index = $columns[$date];
$reader_index = $columns[$reader];
$list['index']['id'] = $primarykey_index;
$list['index']['name'] = $primaryname_index;
$list['index']['date'] = $date_index;
$list['index']['reader'] = $reader_index;
$list['index']['format'] = $format_index;
$hidden_field_array = explode(",", $hidden_field);
$i = 0;
for (; $i < sizeof($hidden_field_array); ++$i) {
$element = explode(":", $hidden_field_array[$i]);
$index_name = $columns[(bool) $element[1]];
switch ($element[2]) {
case "name":
$index_id = $USER_ID;
$index[++$j - 1] = $index_name . "='" . $index_id . "'";
break;
case "dept":
$index_id = $_SESSION[$SUNSHINE_USER_DEPT_VAR];
$index[++$j - 1] = $index_name . "='" . $index_id . "' or " . $index_name . "='0'";
}
}
is_array($index) ? $index_sql = join(" ", $index) : ($index_sql = "");
6 < strlen($index_sql) ? $index_sql = "where " . $index_sql : ($index_sql = "");
switch ($functionname) {
case "url_dataline_view":
$functionname = "url_dataline_view";
$sql = "select {$primarykey_index},{$primaryname_index},{$date_index},{$reader_index},USER from {$tablename} where USER='' or USER='{$USER_ID}' order by {$date_index}";
$rs = $db->selectlimit($sql, 60);
break;
case "dataline_view":
$functionname = "dataline_view";
$reader_index == "" ? "" : ($reader_index = "," . $reader_index);
$sql = "select {$primarykey_index},{$primaryname_index},{$date_index}" . $reader_index . " from {$tablename} {$index_sql} order by {$date_index} desc";
$rs = $db->selectlimit($sql, 6);
break;
default:
$functionname = "dataline_view";
$sql = "select {$primarykey_index},{$primaryname_index},{$date_index},{$reader_index} from {$tablename} {$index_sql} order by {$date_index} desc";
$rs = $db->selectlimit($sql, 6);
break;
}
$rs_a = $rs->getarray();
$list['body'] = $rs_a;
$list['header']['name'] = $common_html['common_html'][$tablename];
$list['bottom'] = $common_html['common_html']['more'];
$list['link'] = $link;
$list['width'] = $width;
$list['format'] = $format;
$list['tablename'] = $tablename;
$functionname($list);
}
示例7: returnsystemlang
$ColumnName = $Column[$ii];
if ($ColumnName == "编号") {
$ColumnValue = $i + 1;
} else {
$ColumnValue = $rs_a[$i][$ColumnName];
}
print "<td nowrap>" . $ColumnValue . "</td>";
}
print "</tr>";
}
print "</table>";
exit;
}
//统计项
if ($_GET['action'] == "init_default" || $_GET['action'] == "") {
$html_etc = returnsystemlang('edu_xingzheng_kaoqinmingxi');
page_css("行政人员卡机考勤按月份查询");
//此段代码以前为周次统计之前,月份统计之下,后需要用到学期名称,所以提前至此
if ($_GET['学期名称'] != "") {
$学期名称 = $_GET['学期名称'];
} else {
$学期名称 = returntablefield("edu_xueqiexec", "当前学期", '1', "学期名称");
}
$学期初始值 = $学期名称;
$sql = "select 开始时间,学期名称 from edu_xueqiexec where 当前学期='1' order by 流水号 desc limit 1";
$rs = $db->CacheExecute(150, $sql);
$rs_a = $rs->GetArray();
$开始时间 = $rs_a[0]['开始时间'];
//$学期名称 = $rs_a[0]['学期名称'];
$开始时间Array = explode('-', $开始时间);
print "\n\t\t<table border=0 class=TableBlock width=100% >\n\t\t<tr class=TableHeader><td valign=bottom align=left>行政人员卡机考勤管理 " . $html_etc['edu_xingzheng_kaoqinmingxi']['学期'] . ":";
示例8: online_userelement
function online_userelement($userid, $username, $userprivname, $usergif = "9.gif")
{
global $common_html;
global $user_online_num;
if (isset($userid, $username)) {
++$user_online_num;
}
}
require_once "lib.inc.php";
require_once "../Enginee/newai.php";
$sessionkey = returnsesskey();
$GLOBAL_SESSION = returnsession();
$systemlang = $_SESSION[$SUNSHINE_USER_LANG_VAR];
$ExecTimeBegin = getmicrotime();
$lang = returnsystemlang();
$common_html = returnsystemlang("common_html");
$LOGIN_THEME = $_SESSION['LOGIN_THEME'];
$LOGIN_THEME == "" ? $LOGIN_THEME = $SYSTEM_THEME : "";
$sql = "select * from sessions where data IS NOT NULL";
$rs = $db->execute($sql);
$user_online_num = 0;
while (!$rs->EOF) {
$DATA = urldecode($rs->fields['DATA']);
$sess_array = explode(";", $DATA);
$i = 0;
for (; $i < sizeof($sess_array); ++$i) {
$sess_array_in = explode("|", $sess_array[$i]);
$name = $sess_array_in[0];
$value_array = explode(":", $sess_array_in[1]);
$value = $value_array[sizeof($value_array) - 1];
$GLOBAL_SESSION_LIST_INDEX[$name] = ereg_replace("\"", "", $value);
示例9: ini_set
<?php
ini_set('display_errors', 1);
ini_set('error_reporting', E_ALL);
// display warnings and errors
error_reporting(E_WARNING | E_ERROR);
require_once 'lib.inc.php';
$GLOBAL_SESSION = returnsession();
$common_html = returnsystemlang('common_html');
$html_etc = returnsystemlang('SERVERINFOR');
require_once 'about.php';
示例10: newaiReport
//.........这里部分代码省略.........
}
} else {
if (file_exists($fileName)) {
require_once $fileName;
$functionName = $functionName . "_Value";
if (function_exists($functionName)) {
$ReportData[$filterName] = $functionName($fields['value'][$counter][$list_index], $fields, $counter);
} else {
print "函数名称[{$functionName}]不存在!";
}
} else {
print "没有相应文件,文件名:{$fileName}";
}
}
break;
}
}
//数据过滤区 - End ##################################################
print "<BR>";
table_begin("80%");
print "<TR class=TableHeader>";
print "<TD noWrap colspan=4>" . $html_etc[$tablename][$tablename] . $common_html['common_html']['report'] . " </TD>";
print "</TR>";
$Counter = 0;
for ($i = 0; $i < sizeof($showlistfieldlistArray); $i += 2) {
$fieldName1 = (string) $columns[(string) $showlistfieldlistArray[$i]];
$k = $i + 1;
$fieldName2 = (string) $columns[(string) $showlistfieldlistArray[$k]];
print "<TR class=TableData>";
print "<TD noWrap width=15%>" . $html_etc[$tablename][$fieldName1] . " </TD>";
print "<TD width=35%>" . $ReportData[$fieldName1] . " </TD>";
print "<TD noWrap width=15%>" . $html_etc[$tablename][$fieldName2] . " </TD>";
print "<TD width=35%>" . $ReportData[$fieldName2] . " </TD>";
print "</TR>";
}
table_end();
}
//end of rs_array
//##############################################################################
//实现子目录列表
global $child_tablename, $child_showlistfieldlist;
global $child_partent, $child_showlistfieldfilter;
//子目录列表开始
if ($child_tablename != "" && $child_showlistfieldlist != "") {
$child_columns = returntablecolumn($child_tablename);
$child_html_etc = returnsystemlang($child_tablename);
table_begin("80%");
print "<TR class=TableHeader>";
print "<TD noWrap width=100% colspan=32>" . $child_html_etc[$child_tablename]["list" . $child_tablename] . " </td>";
print "</TR>";
print "<TR class=TableHeader>";
$child_showlistfieldlist_Array = explode(",", $child_showlistfieldlist);
$child_showlistfieldfilter_Array = explode(",", $child_showlistfieldfilter);
for ($i = 0; $i < sizeof($child_showlistfieldlist_Array); $i++) {
$child_index = $child_showlistfieldlist_Array[$i];
$indexName = $child_columns[$child_index];
print "<TD noWrap>" . $child_html_etc[$child_tablename][$indexName] . " </td>";
}
print "</TR>";
//子表与父表关联部分
$child_partent_Array = explode(":", $child_partent);
$sql = "select * from {$child_tablename} where " . $child_columns[(string) $child_partent_Array[0]] . "='" . $list . "'";
$rs = $db->CacheExecute(150, $sql);
$rs_a = $rs->GetArray();
for ($i = 0; $i < sizeof($rs_a); $i++) {
print "<TR class=TableData>";
for ($j = 0; $j < sizeof($child_showlistfieldlist_Array); $j++) {
$child_index = $child_showlistfieldlist_Array[$j];
$indexName = $child_columns[$child_index];
$ChildValue = $rs_a[$i][$indexName];
$filterType = $child_showlistfieldfilter_Array[$j];
$TypeNameFilterArray = explode(":", $filterType);
switch ($TypeNameFilterArray[0]) {
case 'input':
break;
case 'boolean':
$ChildValue = returnboolean($ChildValue);
break;
case 'tablefilter':
$filterTableName = $TypeNameFilterArray[1];
$filterTableColumns = returntablecolumn($filterTableName);
$filterTableFieldID = $filterTableColumns[(string) $TypeNameFilterArray[2]];
$filterTableFieldName = $filterTableColumns[(string) $TypeNameFilterArray[3]];
$filterResultText = returntablefield($filterTableName, $filterTableFieldID, $ChildValue, $filterTableFieldName);
$ChildValue = $filterResultText;
break;
}
print "<TD noWrap>" . $ChildValue . " </td>";
}
print "</TR>";
}
UserDefineFunction($list);
table_end();
print "<BR>";
print "<hr width=\"80%\" height=\"1\" align=\"{$align}\" color=\"white\">";
print "<BR>";
}
//子目录列表结束
//##############################################################################
}
示例11: print_select_four_address
function print_select_four_address($ValueArray, $SYSTEM_TABLE)
{
$showfield = "city";
$tablename = "dict_cities";
$field_value = "City_ID";
$field_name = "City";
$where = "Province_ID";
$where_value = "1";
$where_table = "dict_provinces";
$where_table_value = "Province_ID";
$where_table_name = "Province";
$colspan = 1;
//附加字段 - 用于语言显示
$province = "provinces";
$City = $showfield;
$postcode = "postcode";
$cityCode = "cityCode";
global $db, $html_etc;
$sql = "select {$field_value},{$field_name},{$where},Area_Code,ZIP from {$tablename} order by {$field_value}";
$rst = $db->Execute($sql);
print "<SCRIPT language=JavaScript>\n";
//-----data
print "var onecount;\n";
print "onecount=0;\n";
print "subcat = new Array();\n";
$i = 0;
while (!$rst->EOF) {
print "subcat[{$i}] = new Array(\"" . $rst->fields[$field_name] . "\",\"" . $rst->fields[$where] . "\",\"" . $rst->fields[$field_value] . "\",\"" . $rst->fields['Area_Code'] . "\",\"" . $rst->fields['ZIP'] . "\");\n";
$i++;
$rst->MoveNext();
}
print "onecount={$i};\n";
//----deal_data_begin
print "function changelocation(locationid)\n";
print "{\n";
print " document.form1.{$showfield}.length = 0; \n";
print " document.form1.{$cityCode}.length = 0; \n";
print " document.form1.{$postcode}.length = 0; \n";
print " var locationid=locationid;\n";
print " var i;\n";
print " for (i=0;i<onecount;i++)\n";
print " {\n";
print " if (subcat[i][1] == locationid)\n";
print " { \n";
print " document.form1.{$showfield}.options[document.form1.{$showfield}.length] = new Option(subcat[i][0], subcat[i][2]);\n";
//print " document.form1.$cityCode.options[document.form1.$cityCode.length] = new Option(subcat[i][3], subcat[i][3]);\n";
print " document.form1.{$cityCode}.value = subcat[i][3];\n";
//print " document.form1.$postcode.options[document.form1.$postcode.length] = new Option(subcat[i][4], subcat[i][4]);\n";
print " document.form1.{$postcode}.value = subcat[i][4];\n";
print " } \n";
print " }\n";
print "} \n";
print "function changelocation_city(locationid)\n";
print "{\n";
print " document.form1.{$cityCode}.length = 0; \n";
print " document.form1.{$postcode}.length = 0; \n";
print " var locationid=locationid;\n";
print " var i;\n";
print " for (i=0;i<onecount;i++)\n";
print " {\n";
print " if (subcat[i][2] == locationid)\n";
print " { \n";
//print " document.form1.$cityCode.options[document.form1.$cityCode.length] = new Option(subcat[i][3], subcat[i][3]);\n";
print " document.form1.{$cityCode}.value = subcat[i][3];\n";
//print " document.form1.$postcode.options[document.form1.$postcode.length] = new Option(subcat[i][4], subcat[i][4]);\n";
print " document.form1.{$postcode}.value = subcat[i][4];\n";
print " } \n";
print " }\n";
print "} \n";
print "</SCRIPT>\n";
//-----deal_data_end
//#############################################################################
print "<TR><TD class=TableData noWrap width=20%>" . $html_etc[$SYSTEM_TABLE]['country'] . " :</TD><TD class=TableData noWrap>\n";
print "<INPUT class=SmallStatic maxLength=20 name=countryName readonly value=\"中国\" onkeydown=\"if(event.keyCode==13)event.keyCode=9\">";
print "<INPUT type=hidden maxLength=20 name=country value=1>";
//print "<SELECT name=country class=\"SmallSelect\" onkeydown=\"if(event.keyCode==13)event.keyCode=9\">\n";
//print "<OPTION value=\"1\" >中国</OPTION>\n";
//print "</SELECT> \n";
print "</TD></TR>\n";
print "<TR><TD class=TableData noWrap width=20%>" . $html_etc[$SYSTEM_TABLE]['countryCode'] . " :</TD><TD class=TableData noWrap>\n";
print "<INPUT class=SmallStatic maxLength=20 name=countryCode readonly value=\"0086\" onkeydown=\"if(event.keyCode==13)event.keyCode=9\">";
//print "<SELECT name=countryCode class=\"SmallSelect\" onkeydown=\"if(event.keyCode==13)event.keyCode=9\">\n";
//print "<OPTION value=\"0086\" >0086</OPTION>\n";
//print "</SELECT> \n";
print "</TD></TR>\n";
//#############################################################################
$html_etc_where_table = returnsystemlang($where_table);
print "<TR><TD class=TableData noWrap width=20%>" . $html_etc[$SYSTEM_TABLE][$province] . " :</TD><TD class=TableData noWrap>\n";
print "<SELECT id={$province} onkeydown=\"if(event.keyCode==13)event.keyCode=9\" class=\"SmallSelect\" onchange=changelocation(document.form1.{$province}.options[document.form1.{$province}.selectedIndex].value) \n";
print "size=1 name={$province}>\n";
$sql = "select {$where_table_value},{$where_table_name} from {$where_table} order by {$where_table_value}";
$rse = $db->Execute($sql);
//print $sql;//exit;
while (!$rse->EOF) {
$rse->fields[$where_table_value] == $ValueArray[$province] ? $selected = 'selected' : ($selected = '');
print "<OPTION value=\"" . $rse->fields[$where_table_value] . "\" {$selected}>" . $rse->fields[$where_table_name] . "</OPTION>\n";
$rse->MoveNext();
}
print "</SELECT> </TD></TR>\n";
print "<TR><TD class=TableData noWrap width=20%>" . $html_etc[$SYSTEM_TABLE][$City] . " :</TD><TD class=TableData noWrap>\n";
//.........这里部分代码省略.........
示例12: explode
$rs = $db->Execute($field_sql);
print "<div align=center><span style=\"BACKGROUND:#EEEEEE;COLOR:#FF6633;margin: 10px;border:1px dotted #FF6633;font-weight:bold;padding:8px;width=300px\">\n\t\t<font color=#FF0000><img src=\"images/attention.gif\" height=20> <b>提示</b></font><hr>\n\t\t对象构建完成,对象名称为 " . $_GET['Tablename'] . "</span></div>\n\t\t<br>\n\t\t<div align=center>\n\t\t\t<input type=button accesskey='r' value=\"初始化对象:" . $_GET['Tablename'] . "\" class=\"SmallButton\" onclick=\"location='php_ide.php?tablename=" . $_GET['Tablename'] . "&action=init'\">\n\t\t</div>";
exit;
}
$Tablename = $_GET['Tablename'];
$TablenameArray = explode('_', $Tablename);
$TempName = $TablenameArray[sizeof($TablenameArray) - 1];
if (sizeof($TablenameArray) >= 3 && ($TempName == "input" || $TempName == "edit" || $TempName == "read")) {
$addTablename = true;
array_pop($TablenameArray);
$Tablerealname = join('_', $TablenameArray);
} else {
$addTablename = false;
$Tablerealname = $Tablename;
}
$html_etc = returnsystemlang($Tablerealname);
$columns = returntablecolumn($Tablerealname);
//print_R($columns);
$sql = "select * from {$Tablerealname}";
$MetaColumns = $db->MetaColumns($Tablerealname);
//MetaDatabases MetaTables MetaColumns MetaColumnNames MetaPrimaryKeys ServerInfo
//print_R($MetaColumns);
//$Attribute = array("name","max_length","type","not_null","default_value","primary_key","auto_increment","binary");
//$AttributeName = array("字段名称","最大长度","类型","非空","默认值","主键","自动增量","二进制");
$Attribute = array("name", "max_length", "type", "not_null", "default_value", 'other');
$AttributeName = array("字段名称", "最大长度", "类型", "非空", "默认值", "操作");
print "\n<FORM name=form1 action=\"?Tablename=" . $Tablerealname . "§ionName=sectionName_data\" method=post encType=multipart/form-data>\n";
print "<table border=1 cellspacing=0 class=small bordercolor=#000000 cellpadding=3 align=center style=\"border-collapse:collapse\">\n";
print "<TR>\n";
print "<TD class=TableHeader nowrap colSpan=6> 表名:" . $Tablerealname . "</TD>";
print "</TR>\n";
示例13: CheckSystemPrivate
CheckSystemPrivate("教务管理-教学基本信息-教学计划","数字化校园系统设置-教师任教设置");
//######################教育组件-权限较验部分##########################
session_register("SYSTEM_CURRENT_XUEQI");
if($_GET['学期名称']!="") {
$_SESSION['SYSTEM_CURRENT_XUEQI'] = $_GET['学期名称'];
}
if($_SESSION['SYSTEM_CURRENT_XUEQI']=="") {
$当前学期名称 = returntablefield("edu_xueqiexec","当前学期",'1',"学期名称");
$_SESSION['SYSTEM_CURRENT_XUEQI'] = $当前学期名称;
}
$_GET['学期名称'] = $_SESSION['SYSTEM_CURRENT_XUEQI'];
$html_etc =returnsystemlang("edu_planexec");
$common_html=returnsystemlang('common_html');//print_R($common_html);
page_css("教学计划执行与执行");
?>
<script language="javascript" src="../LODOP60/LodopFuncs.js"></script>
<object id="LODOP" classid="clsid:2105C259-1E0C-4534-8141-A753534CB4CA" width=0 height=0>
<embed id="LODOP_EM" type="application/x-print-lodop" width=0 height=0 pluginspage="../LODOP60/install_lodop.exe"></embed>
</object>
<script language="javascript" type="text/javascript">
var LODOP; //声明为全局变量
LODOP=getLodop(document.getElementById('LODOP'),document.getElementById('LODOP_EM'));
function PreviewFun(){
示例14: mysql_escape_string
$tabledump .= "'" . mysql_escape_string($row[$fieldcounter]) . "'";
}
}
$tabledump .= ");\n";
if ($fp) {
fwrite($fp, $tabledump);
} else {
echo $tabledump;
}
}
mysql_free_result($rows);
}
require_once "lib.inc.php";
$GLOBAL_SESSION = returnsession();
$common_html = returnsystemlang("common_html");
$html_etc = returnsystemlang("SERVERINFOR");
page_css("System Information");
if (function_exists("ini_get")) {
$onoff = ini_get("register_globals");
} else {
$onoff = get_cfg_var("register_globals");
}
if ($onoff != 1) {
@extract($_POST, EXTR_SKIP);
@extract($_GET, EXTR_SKIP);
}
$self = $_SERVER['PHP_SELF'];
$servername = isset($servername) ? $servername : "localhost";
$dbusername = isset($dbusername) ? $dbusername : "root";
$dbpassword = isset($dbpassword) ? $dbpassword : "";
$dbname = isset($dbname) ? $dbname : "";
示例15: returntablecolumn
}
</script>
<?php
require_once 'config.php';
require_once '../adodb/adodb.inc.php';
if ($SYSTEM_MODE_DIR == "WUYE") {
require_once '../Interface/WUYE/config.inc.php';
} else {
require_once '../config.inc.php';
}
require_once '../setting.inc.php';
require_once '../adodb/session/adodb-session2.php';
require_once '../Enginee/lib/init.php';
$tablename = $_GET['tablename'];
$columns = returntablecolumn($tablename);
$html_etc2 = returnsystemlang($tablename);
$showlistfieldlist2 = $_GET['showlistfieldlist2'];
$arrayfield = explode(",", $showlistfieldlist2);
print "<table border=1 cellspacing=0 class=small bordercolor=#000000 cellpadding=3 align=center width=100% style=\"border-collapse:collapse\">\n";
print "<tr><td class=TableHeader><input type=\"checkbox\" name=\"allbox\" onclick=\"check_all();\"></td><td class=TableHeader>±àºÅ</td><td class=TableHeader>×Ö¶Î</td><td class=TableHeader>Ãû³Æ</td></tr>";
for ($i = 0; $i < sizeof($columns); $i++) {
$selected = "";
for ($j = 0; $j < sizeof($arrayfield); $j++) {
if ($arrayfield[$j] == $i) {
$selected = "checked";
break;
}
}
?>
<tr><td><input type="checkbox" value=<?php
echo $i;