本文整理汇总了PHP中createPage函数的典型用法代码示例。如果您正苦于以下问题:PHP createPage函数的具体用法?PHP createPage怎么用?PHP createPage使用的例子?那么, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了createPage函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: execute
//.........这里部分代码省略.........
// all is well. Get the translated content id
$tcid = $dmRecord['meaning_text_tcid'];
for ( $columnIndex = 2; $columnIndex < count( $columns ); $columnIndex++ ) {
// Google docs removes empty columns at the end of a row,
// so if column index is higher than the length of the row, we can break
// and move on to the next defined meaning.
if ( columnIndex >= count( $row ) ) {
break;
}
$columnValue = $row[$columnIndex];
if ( !$columnValue ) {
continue;
}
$columnName = $columns[$columnIndex];
$langCode = substr( $columnName, strrpos( $columnName, '_' ) + 1 );
$langId = getLanguageIdForIso639_3( $langCode );
if ( strpos( $columnName, 'definition' ) === 0 ) {
if ( !translatedTextExists( $tcid, $langId ) ) {
if ( $testRun ) {
$wgOut->addHTML( "Would add definition for $exp ($dmid) in $langCode: $columnValue.<br />" );
} else {
addTranslatedText( $tcid, $langId, $columnValue );
$wgOut->addHTML( "Added definition for $exp ($dmid) in $langCode: $columnValue.<br />" );
$definitions++;
}
}
}
if ( strpos( $columnName, 'translation' ) === 0 ) {
$spellings = explode( '|', $columnValue );
foreach ( $spellings as $spelling ) {
$spelling = trim( $spelling );
$expression = findExpression( $spelling, $langId );
if ( !$expression ) { // expression does not exist
if ( $testRun ) {
$wgOut->addHTML( "Would add translation for $exp ($dmid) in $langCode: $spelling. Would also add new page.<br />" );
}
else {
$expression = createExpression( $spelling, $langId );
$expression->bindToDefinedMeaning( $dmid, 1 );
// not nescesary to check page exists, createPage does that.
$title = getPageTitle( $spelling );
createPage( 16, $title );
$wgOut->addHTML( "Added translation for $exp ($dmid) in $langCode: $spelling. Also added new page.<br />" );
$translations++;
}
}
else { // expression exists, but may not be bound to this defined meaning.
if ( !$expression->isBoundToDefinedMeaning( $dmid ) ) {
if ( $testRun ) {
$wgOut->addHTML( "Would add translation for $exp ($dmid) in $langCode: $spelling.<br />" );
}
else {
$expression->bindToDefinedMeaning( $dmid, 1 );
$wgOut->addHTML( "Added translation for $exp ($dmid) in $langCode: $spelling.<br />" );
$translations++;
}
}
}
}
}
}
}
if ( $definitions == 0 && $translations == 0 ) {
$wgOut->addHTML( "<br />" );
if ( $testRun ) {
$wgOut->addHTML( wfMsg( 'ow_importtsv_nothing_added_test' ) );
}
else {
$wgOut->addHTML( wfMsg( 'ow_importtsv_nothing_added' ) );
}
$wgOut->addHTML( "<br />" );
}
else {
$wgOut->addHTML( "<br />" . wfMsgExt( 'ow_importtsv_results', 'parsemag', $definitions, $translations ) . "<br />" );
}
}
else {
// render the page
$wgOut->setPageTitle( wfMsg( 'ow_importtsv_title2' ) );
$wgOut->addHTML( wfMsg( 'ow_importtsv_header' ) );
$wgOut->addHTML( getOptionPanelForFileUpload(
array(
wfMsg( 'ow_importtsv_file' ) => getFileField( 'tsvfile' ),
wfMsg( 'ow_importtsv_test_run' ) => getCheckBox( 'testrun', true )
)
) );
}
}
示例2: createPage
?>
">
<input type="hidden" name="code" value="<?php
echo $_REQUEST['code'];
?>
">
<input type="hidden" name="act" value="<?php
echo $actImage;
?>
">
<input type="hidden" name="lang" value="<?php
echo $_lang_A;
?>
">
<?php
$pageindex = createPage(countRecord($tableImageId, $whereComment), './?act=' . $actImage . '&codeParent=' . $_REQUEST['codeParent'] . '&idComment=' . $_REQUEST['idComment'] . '&code_frame=' . $_REQUEST['code_frame'] . '&code_module=' . $_REQUEST['code_module'] . '&code=' . $_REQUEST['code'] . '&page=', $MAXPAGE, $page, '10', $_lang_A);
//phan trang
if ($_GET['code'] == 1) {
$errMsg = ASUCCESSFULLY;
}
//kiem tra cap nhat thanh cong hay chua
?>
<table cellspacing="0" cellpadding="0" width="100%">
<tr>
<?php
echo $totalItems > $MAXPAGE ? '<td height="30" class="smallfont" align="left" valign="middle" >Page :' . $pageindex . '</td>' : '';
?>
<td height="30" align="right" valign="middle" class="smallfont">
示例3: createPage
}
$errMsg = "Đã xóa " . $cnt . " đơn hàng.<br><br>";
$errMsg .= $cntNotDel > 0 ? 'Không thể xóa ' . $cntNotDel . ' đơn hàng, vì vẫn còn sản phẩm tồn tại trong chi tiết đơn hàng !' : $cntNotDel;
} else {
$errMsg = 'Hãy chọn trước khi xóa !';
}
}
?>
<form method="POST" name="frmForm" action="./">
<input type="hidden" name="act" value="order">
<input type=hidden name="page" value="<?php
echo $page;
?>
">
<?php
$pageindex = createPage(countRecord("tbl_order", "1=1"), './?act=order"."&page=', $MAXPAGE, $page);
?>
<table cellspacing="0" cellpadding="0" width="100%">
<tr><td height="30" class="smallfont">Trang : <?php
echo $pageindex;
?>
</td></tr>
</table>
<table border="1" cellpadding="2" bordercolor="#C9C9C9" width="100%">
<tr>
<th width="20" class="title"><input type="checkbox" name="chkall" onclick="chkallClick(this);"></th>
<th width="20" class="title"></th>
<th width="80" class="title">Chi tiết</th>
<th width="20" class="title">ID</th>
示例4: countRecord
$parentWhereConfig = '';
$errMsg = '';
$totalItems = countRecord($tableUser, $parentWhereConfig);
//FILE xoa mau tin
if (!$_SESSION['level'] < 2 and $_REQUEST['id'] != '4') {
include 'delete.php';
}
//Update Order
include 'updateOrder.php';
//Update Show
include 'updateShow.php';
if ($_GET['code'] == 1) {
$errMsg = 'Successfully updated.';
}
//kiem tra cap nhat thanh cong hay chua
$pageindex = createPage(countRecord($tableUser, $parentWhereConfig), './?act=' . $actUser . '&codeParent=' . $_REQUEST['codeParent'] . '&name=' . $_REQUEST['name'] . '&ma=' . $_REQUEST['ma'] . '&page=', $MAXPAGE, $page, '30', $_lang_A);
//phan trang
$pageindexHtml = $totalItems > $MAXPAGE ? '<td height="30" class="smallfont" align="left" valign="middle" >Page :' . $pageindex . '</td>' : '';
if ($errMsg != '') {
$errMsgHtml = '<p align=center class="err">' . $errMsg . '<br></p>';
}
$sql = "select *,DATE_FORMAT(date_added,'%d/%m/%Y %h:%i') as dateAdd,DATE_FORMAT(last_modified,'%d/%m/%Y %h:%i') as dateModify from {$tableUser}";
$result = @mysql_query($sql, $conn);
$i = 0;
while ($row = @mysql_fetch_array($result)) {
$color = $i++ % 2 ? '#d5d5d5' : '#e5e5e5';
if ($row['status'] == 0) {
$showNotshow = " <a href=\"./?act=" . $actUser . "&action=notshow&codeParent=" . $_REQUEST['codeParent'] . "&id=" . $row['id'] . "&page=" . $_REQUEST['page'] . "&lang=" . $_lang_A . "\"><img border=\"0\" src=\"images/show.gif\" alt=\"" . TSHOW . "\" height=\"20\"/></a>";
} else {
$showNotshow = "<a href=\"./?act=" . $actUser . "&action=show&codeParent=" . $_REQUEST['codeParent'] . "&id=" . $row['id'] . "&page=" . $_REQUEST['page'] . "&lang=" . $_lang_A . "\"><img border=\"0\" src=\"images/notshow.gif\" alt=\"" . TNOTSHOW . "\" height=\"20\"/></a>";
}
示例5: session_start
<?php
session_start();
// // Display any php errors (for development purposes)
error_reporting(E_ALL);
ini_set('display_errors', '1');
require_once __DIR__ . '/../../config.php';
// Include API Calls
require_once 'wizardAPI.php';
require_once 'simple_html_dom.php';
$homePage = getPageFromCourse($courseID, "home");
if (isset($homePage->created_at)) {
if ($homePage->created_at !== '') {
echo 'Already Exists';
exit;
}
}
if ($_POST['createPage'] == true) {
$frontPageTitle = 'Home';
$frontPageBody = '';
$frontPageParams = 'wiki_page[title]=' . $frontPageTitle . '&wiki_page[body]=' . urlencode($frontPageBody) . '&wiki_page[published]=true&wiki_page[front_page]=true';
$newPage = createPage($courseID, $frontPageParams);
$responseData = json_decode($newPage, true);
$page_url = $responseData['url'];
echo '<i class="fa fa-check"></i> Page Created';
}
示例6: countRecord
} else {
$parentWhereConfig1 = $whereStatus;
}
$parentWhereConfig = $parentWhereConfig1;
$parentWhereConfigDEA = "id=" . $codeParent . " and {$whereStatus}";
$totalDetele = 1;
//countRecord($tableCategoryConfigId,$parentWhereConfigDEA.$parentWhereConfigDefaultDetele);
$totalEdit = 1;
//countRecord($tableCategoryConfigId,$parentWhereConfigDEA.$parentWhereConfigDefaultEdit);
$totalAddnew = 1;
//countRecord($tableCategoryConfigId,$parentWhereConfigDEA.$parentWhereConfigDefaultAddnew);
//DINH SO PHAN TRANG=======================================================[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[
/*--------KIEM TRA THUOC TINH---------------------*/
//$defaulType = getRecord($tableCategoryConfigId," id=".$_REQUEST['codeParent']." and ".$whereStatus);
$totalItems = countRecord($tableCityId, $parentWhereConfig);
$pageindex = createPage(countRecord($tableCityId, $parentWhereConfig), './?act=' . $actCity . '&module_city=' . $_REQUEST['module_city'] . '&page=', $MAXPAGE, $page, '30', $_lang_A);
//phan trang
$showPageIndex = $totalItems > $MAXPAGE ? '<td height="30" class="smallfont" align="left" valign="middle" >' . TPAGE . ' :' . $pageindex . '</td>' : '';
//TIEU DE CUA COT=====================================================================[[[[[[[[[[[[[[[[[[[]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]
//SAC DINH THANH VIEN NAY CO CHO XOA KO==============
if ($totalDetele > 0) {
$trDetele_1title = "<th width=\"20\" class=\"title\"><input type=\"checkbox\" name=\"chkall\" onClick=\"chkallClick(this);\"></th>";
$trDetele_2title = "<th align=\"center\" valign=\"middle\" class=\"title\"> </th>";
$trDetele_1bottom = "<td></td>";
$trDeteleAllbottom = "<input type=\"submit\" value=\"" . TDELETESELECTSD . "\" name=\"btnDel\" onClick=\"return confirm('" . AAREYOUDELETE . "');\" class=\"button\">";
}
//SAC DINH THANH VIEN NAY CO CHO XOA KO==============
//SAC DINH THANH VIEN NAY CO CHO SUA KO==============
if ($totalEdit > 0) {
$trEdit_1title = "<th align=\"center\" valign=\"middle\" class=\"title\"> </th>";
$trEdit_1bottom = "<td></td>";
示例7: elseif
$session->redirectUrl = $page->path . "add/";
} elseif (!$input->post->submit) {
$content = renderPage('ip_registration');
} else {
// Register Service
$user = wire('user')->name;
$parent = $pages->get($page->id);
$operator = wire('user')->id;
if ($pages->get("template=staticip, title={$input->post->mac}") instanceof Nullpage) {
// Creat IP
do {
$ip = long2ip(rand(ip2long("{$pages->get('template=site-setting')->start_ip}"), ip2long("{$pages->get('template=site-setting')->end_ip}")));
} while (!$pages->get("template=staticip, static_ip={$ip}") instanceof NullPage);
// Add new if not exist
$mac = strtoupper($input->post->mac);
$s = createPage('staticip', $parent, $mac);
$s->subtitle = $input->post->title;
$s->operator = $operator;
$s->static_ip = $ip;
$s->save();
} else {
// Update if exit
$operator = wire('user')->id;
$s = $pages->get("title={$input->post->mac}");
$s->operator = $operator;
$s->key = $input->post->key;
$s->of(false);
$s->save();
$s->of(true);
}
$content = "<h2>Node Hinzugefügt:</h2>\n <p>\n Titel: {$s->subtitle}<br>\n MAC : {$s->title}<br>\n IP : {$s->static_ip}<br>\n Betreiber: {$users->get($s->operator)->name}\n </p>";
示例8: countRecord
$parentWhereConfig1 = "name like '%" . $_GET['name'] . "%' and {$whereStatus}";
}
$parentWhereConfig = $parentWhereConfig1;
$parentWhereConfigDEA = "id=" . $codeParent . " and {$whereStatus}";
$totalDetele = 1;
//countRecord($tableCategoryConfigId,$parentWhereConfigDEA.$parentWhereConfigDefaultDetele);
$totalEdit = 1;
//countRecord($tableCategoryConfigId,$parentWhereConfigDEA.$parentWhereConfigDefaultEdit);
$totalAddnew = 1;
//countRecord($tableCategoryConfigId,$parentWhereConfigDEA.$parentWhereConfigDefaultAddnew);
//DINH SO PHAN TRANG=======================================================[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[
/*--------KIEM TRA THUOC TINH---------------------*/
//$defaulType = getRecord($tableCategoryConfigId," id=".$_REQUEST['codeParent']." and ".$whereStatus);
$MAXPAGE = 20;
$totalItems = countRecord($tableMemberId, $parentWhereConfig);
$pageindex = createPage(countRecord($tableMemberId, $parentWhereConfig), './?act=' . $actVoucher . '&page=', $MAXPAGE, $page, '30', $_lang_A);
//phan trang
$showPageIndex = $totalItems > $MAXPAGE ? '<td height="30" class="smallfont" align="left" valign="middle" >' . TPAGE . ' :' . $pageindex . '</td>' : '';
//TIEU DE CUA COT=====================================================================[[[[[[[[[[[[[[[[[[[]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]
//SAC DINH THANH VIEN NAY CO CHO XOA KO==============
if ($totalDetele > 0) {
$trDetele_1title = "<th width=\"20\" class=\"title\"><input type=\"checkbox\" name=\"chkall\" onClick=\"chkallClick(this);\"></th>";
$trDetele_2title = "<th align=\"center\" valign=\"middle\" class=\"title\"> </th>";
$trDetele_1bottom = "<td></td>";
$trDeteleAllbottom = "<input type=\"submit\" value=\"" . TDELETESELECTSD . "\" name=\"btnDel\" onClick=\"return confirm('" . AAREYOUDELETE . "');\" class=\"button\">";
}
//SAC DINH THANH VIEN NAY CO CHO XOA KO==============
//SAC DINH THANH VIEN NAY CO CHO SUA KO==============
if ($totalEdit > 0) {
$trEdit_1title = "<th align=\"center\" valign=\"middle\" class=\"title\"> </th>";
$trEdit_1bottom = "<td></td>";
示例9: ODP
//.........这里部分代码省略.........
$p = $output_pages->createElement('text:p');
$line->appendChild($p);
$page->appendChild($line);
//Content
$page->appendChild(drawAgendaList("gr4", "P5", "L2", "T3", "L2", "T4", "10cm", "4.5cm", "3.5cm", "5cm", $tpl_msg['odp_agenda_introduction']));
$text = $tpl_msg['odp_agenda_solutions'];
foreach ($names as $name) {
array_push($text, $name);
}
$page->appendChild(drawAgendaList("gr5", "P5", "L4", "T5", "L4", "T4", "10cm", "4.5cm", "3.5cm", "11.7cm", $text));
$page->appendChild(drawAgendaList("gr6", "P5", "L5", "T8", "L5", "T4", "12cm", "4.5cm", "15cm", "5cm", $tpl_msg['odp_agenda_synthesis']));
if ($tpl_msg['odp_agenda_reco']) {
$page->appendChild(drawAgendaList("grV", "P5", "LV", "TV", "LV", "T4", "12cm", "4.5cm", "15cm", "11.7cm", $tpl_msg['odp_agenda_reco']));
}
return $page;
}
function getList($element, $style)
{
global $output_pages;
$list = $output_pages->createElement('text:list');
$list->setAttribute("text:style-name", $style);
$item = $output_pages->createElement('text:list-item');
if (is_array($element)) {
foreach ($element as $subelement) {
$item->appendChild(getList($subelement, $style));
}
} else {
$text = $output_pages->createElement('text:p', $element);
$item->appendChild($text);
}
$list->appendChild($item);
return $list;
}
function createPage($name, $type, $title, $tab_title, $contents, $image = null)
{
global $output_pages, $tempdir;
$page = $output_pages->createElement('draw:page');
$page->setAttribute("draw:name", $name);
$page->setAttribute("draw:style-name", "dp1");
$page->setAttribute("draw:master-page-name", $type);
$page->setAttribute("presentation:presentation-page-layout-name", "AL2T1");
$page->setAttribute("presentation:use-footer-name", "ftr1");
$page->setAttribute("presentation:use-date-time-name", "dtd1");
//Title
$page->appendChild(drawPageTitle($title));
//Tab title
$page->appendChild(drawTabTitle($tab_title));
//Image positioning
if ($image) {
//Default dimensions and positioning for SVG images
$x = 0.15;
$y = 2.5;
$width = 26.457;
$height = 15.874;
if (substr($image, -3) == "png") {
$ratio = 0.023291;
//(ratio px <=> cm)
//Get image dimensions
$size = getimagesize($tempdir . "/" . $image);
$width = $size[0] * $ratio;
$height = $size[1] * $ratio;
$y = 3.5;
$x = (28 - $size[0] * $ratio) / 2;
//28cm is page width (minus left border) in ODP template, so we center image
//If image height is not very big, put somme space around it
if ($height <= 7) {
示例10: getDayFromBooklineDate
$day = getDayFromBooklineDate($date);
if ($choice_date == null) {
$pdf = createPage($pdf, $d, $sprache, $gastro_id, $date, $cellWidth, $cellHigh);
} else {
if ($choice_date == $day . "/" . $month . "/" . $year) {
$pdf = createPage($pdf, $d, $sprache, $gastro_id, $date, $cellWidth, $cellHigh);
}
}
}
$pdf->Cell($pageWidth, $cellHigh, getUebersetzungGastro("offen", $sprache, $gastro_id), 1, 1);
$res = getReservationsOfVermieter($gastro_id, STATUS_RESERVIERT);
while ($d = $res->FetchNextObject()) {
$reservierungs_id = $d->RESERVIERUNG_ID;
$date = getDatumVonOfReservierung($reservierungs_id);
$year = getYearFromBooklineDate($date);
$month = getMonthFromBooklineDate($date);
$day = getDayFromBooklineDate($date);
if ($choice_date == null) {
$pdf = createPage($pdf, $d, $sprache, $gastro_id, $date, $cellWidth, $cellHigh);
} else {
if ($choice_date == $day . "/" . $month . "/" . $year) {
$pdf = createPage($pdf, $d, $sprache, $gastro_id, $date, $cellWidth, $cellHigh);
}
}
}
$pdf->Line($pdf->GetX(), $pdf->GetY(), $pdf->GetX() + 180, $pdf->GetY());
$pdf->Output();
}
?>
示例11: FPDF
$size[] = $y;
$size[] = $x;
} else {
$size = $dimension;
}
//create the pdf with constructor:
$pdf = new FPDF($pageOrientation, $measureUnit, $size);
if ($showName || $showTime) {
//get the confirmed booking
$res = getReservationsOfVermieter($gastro_id, STATUS_BELEGT);
while ($d = $res->FetchNextObject()) {
$reservierungs_id = $d->RESERVIERUNG_ID;
$gast_id = $d->GAST_ID;
$gast = getMieterVorname($gast_id) . " " . getNachnameOfMieter($gast_id);
$date = getDatumVonOfReservierung($reservierungs_id);
$year = getYearFromBooklineDate($date);
$month = getMonthFromBooklineDate($date);
$day = getDayFromBooklineDate($date);
if ($choice_date == null) {
createPage($pdf, $root . $temp_url, getUebersetzungGastro("Zeit", $sprache, $gastro_id) . ": " . $year . "-" . $month . "-" . $day . " " . getHourFromBooklineDate($date) . ":" . getMinuteFromBooklineDate($date) . " " . getUebersetzungGastro("bis", $sprache, $gastro_id) . " ", getUebersetzungGastro("Name", $sprache, $gastro_id) . ": " . $gast, $headingText, $fontText, $fontTextStyle, $fontTextSize, $fontHeading, $fontHeadingStyle, $fontHeadingSize, $root, $x, $y);
} else {
if ($choice_date == $day . "/" . $month . "/" . $year) {
createPage($pdf, $root . $temp_url, getUebersetzungGastro("Zeit", $sprache, $gastro_id) . ": " . $year . "-" . $month . "-" . $day . " " . getHourFromBooklineDate($date) . ":" . getMinuteFromBooklineDate($date) . " " . getUebersetzungGastro("bis", $sprache, $gastro_id) . " ", getUebersetzungGastro("Name", $sprache, $gastro_id) . ": " . $gast, $headingText, $fontText, $fontTextStyle, $fontTextSize, $fontHeading, $fontHeadingStyle, $fontHeadingSize, $root, $x, $y);
}
}
}
}
$pdf->Output();
}
//end if tableCardId exists
}
示例12: countRecord
$parentWhereConfig1 = "name like '%" . $_REQUEST['name'] . "%' and parent<>0 and {$whereStatus}";
}
$parentWhereConfig = $whereComment;
//$parentWhereConfig1.$parentWhereConfigDefault;
$parentWhereConfigDEA = "id=" . $codeParent . " and parent<>0 and {$whereStatus}";
$totalDetele = 1;
//countRecord($tableCategoryConfigId,$parentWhereConfigDEA.$parentWhereConfigDefaultDetele);
$totalEdit = 1;
//countRecord($tableCategoryConfigId,$parentWhereConfigDEA.$parentWhereConfigDefaultEdit);
$totalAddnew = 1;
//countRecord($tableCategoryConfigId,$parentWhereConfigDEA.$parentWhereConfigDefaultAddnew);
//DINH SO PHAN TRANG=======================================================[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[
/*--------KIEM TRA THUOC TINH---------------------*/
//$defaulType = getRecord($tableCategoryConfigId," id=".$_REQUEST['codeParent']." and ".$whereStatus);
$totalItems = countRecord($tableAdvertisementId, $parentWhereConfig);
$pageindex = createPage(countRecord($tableAdvertisementId, $parentWhereConfig), './?act=' . $actAdvertisement . '&adv_module=' . $_REQUEST['adv_module'] . '&page=', $MAXPAGE, $page, '30', $_lang_A);
//phan trang
$showPageIndex = $totalItems > $MAXPAGE ? '<td height="30" class="smallfont" align="left" valign="middle" >' . TPAGE . ' :' . $pageindex . '</td>' : '';
//TIEU DE CUA COT=====================================================================[[[[[[[[[[[[[[[[[[[]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]
//SAC DINH THANH VIEN NAY CO CHO XOA KO==============
if ($totalDetele > 0) {
$trDetele_1title = "<th width=\"20\" class=\"title\"><input type=\"checkbox\" name=\"chkall\" onClick=\"chkallClick(this);\"></th>";
$trDetele_2title = "<th align=\"center\" valign=\"middle\" class=\"title\"> </th>";
$trDetele_1bottom = "<td></td>";
$trDeteleAllbottom = "<input type=\"submit\" value=\"" . TDELETESELECTSD . "\" name=\"btnDel\" onClick=\"return confirm('" . AAREYOUDELETE . "');\" class=\"button\">";
}
//SAC DINH THANH VIEN NAY CO CHO XOA KO==============
//SAC DINH THANH VIEN NAY CO CHO SUA KO==============
if ($totalEdit > 0) {
$trEdit_1title = "<th align=\"center\" valign=\"middle\" class=\"title\"> </th>";
$trEdit_1bottom = "<td></td>";
示例13: elseif
} elseif ($_REQUEST['name'] != '') {
$parentWhereConfig1 = "name like '%" . $_REQUEST['name'] . "%' and {$whereStatus}";
}
$parentWhereConfig = $parentWhereConfig1;
$parentWhereConfigDEA = "id=" . $codeParent . " and {$whereStatus}";
$totalDetele = 1;
//countRecord($tableCategoryConfigId,$parentWhereConfigDEA.$parentWhereConfigDefaultDetele);
$totalEdit = 1;
//countRecord($tableCategoryConfigId,$parentWhereConfigDEA.$parentWhereConfigDefaultEdit);
$totalAddnew = 1;
//countRecord($tableCategoryConfigId,$parentWhereConfigDEA.$parentWhereConfigDefaultAddnew);
//DINH SO PHAN TRANG=======================================================[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[
/*--------KIEM TRA THUOC TINH---------------------*/
//$defaulType = getRecord($tableCategoryConfigId," id=".$_REQUEST['codeParent']." and ".$whereStatus);
$totalItems = countRecord($tableMemberId, $parentWhereConfig);
$pageindex = createPage(countRecord($tableMemberId, $parentWhereConfig), './?act=' . $actMember . '&mem_module=' . $_REQUEST['mem_module'] . '&page=', $MAXPAGE, $page, '30', $_lang_A);
//phan trang
$showPageIndex = $totalItems > $MAXPAGE ? '<td height="30" class="smallfont" align="left" valign="middle" >' . TPAGE . ' :' . $pageindex . '</td>' : '';
//TIEU DE CUA COT=====================================================================[[[[[[[[[[[[[[[[[[[]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]
//SAC DINH THANH VIEN NAY CO CHO XOA KO==============
if ($totalDetele > 0) {
$trDetele_1title = "<th width=\"20\" class=\"title\"><input type=\"checkbox\" name=\"chkall\" onClick=\"chkallClick(this);\"></th>";
$trDetele_2title = "<th align=\"center\" valign=\"middle\" class=\"title\"> </th>";
$trDetele_1bottom = "<td></td>";
$trDeteleAllbottom = "<input type=\"submit\" value=\"" . TDELETESELECTSD . "\" name=\"btnDel\" onClick=\"return confirm('" . AAREYOUDELETE . "');\" class=\"button\">";
}
//SAC DINH THANH VIEN NAY CO CHO XOA KO==============
//SAC DINH THANH VIEN NAY CO CHO SUA KO==============
if ($totalEdit > 0) {
$trEdit_1title = "<th align=\"center\" valign=\"middle\" class=\"title\"> </th>";
$trEdit_1bottom = "<td></td>";
示例14: viewPage
function viewPage($page, $dir){
if (file_exists($dir.$page)){
echo "<div id='main'>
<ul class='tabs'>
<li class='selected'>
<a href='./index.php?page={$page}'>View</a>
</li>
<li class=''>
<a href='./index.php?page={$page}&edit=true'>Edit</a>
</li>
<li class=''>
<a href='./index.php?page={$page}&delete=true'>Delete</a>
</li>
</ul>
<div class='content'>";
echo "<h1>$page</h1>";
$f = fopen($dir.$page,'r');
$t = date("M j g:i a", filemtime($dir.$path));
$p = fread($f, 25000);
$d = replaceWiki($p,$t);
echo nl2br($d);
} else {
createPage($page);
}
}
示例15: createPage
?>
">
<input type="hidden" name="codeParent" value="<?php
echo $_REQUEST['codeParent'];
?>
">
<input type="hidden" name="act" value="<?php
echo $actCategoryConfig;
?>
">
<input type="hidden" name="lang" value="<?php
echo $_lang_A;
?>
">
<?php
$pageindex = createPage(countRecord($tableCategoryConfigId, $parentWhereConfig), './?act=' . $actCategoryConfig . '&codeParent=' . $_REQUEST['codeParent'] . '&page=', $MAXPAGE, $page, '30', $_lang_A);
//phan trang
if ($_GET['code'] == 1) {
$errMsg = ASUCCESSFULLY;
}
//kiem tra cap nhat thanh cong hay chua
?>
<table cellspacing="0" cellpadding="0" width="100%">
<tr>
<td height="30" align="right" valign="middle" class="smallfont">
<table width="100%" border="0" align="right" cellpadding="0" cellspacing="0">
<tr>
<td colspan="5" align="right" valign="middle" class="smallfont" style="padding-right:5px;">
<table width="100%" border="0" cellspacing="0" cellpadding="0">