当前位置: 首页>>代码示例>>PHP>>正文


PHP displayMenu函数代码示例

本文整理汇总了PHP中displayMenu函数的典型用法代码示例。如果您正苦于以下问题:PHP displayMenu函数的具体用法?PHP displayMenu怎么用?PHP displayMenu使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了displayMenu函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: index

 public function index()
 {
     if (isset($_SESSION[C('USER_AUTH_KEY')])) {
         //显示菜单项
         $menu = array();
         $model = M("AdminMenu");
         if (session("administrator")) {
             //echo 'dd';
         } else {
             //echo 'bb';
             $uid = getMemberId();
             $role = getRole($uid);
             //继续。。
             //获取用户
         }
         $list = $model->where('display=1')->order(array('fid' => 'asc', 'sort' => 'asc'))->select();
         $menu = fetchMenu($list, 0);
         $menu_html = displayMenu($menu, false);
         $this->assign('menu', $menu_html);
     }
     C('SHOW_RUN_TIME', false);
     // 运行时间显示
     C('SHOW_PAGE_TRACE', false);
     $this->display();
 }
开发者ID:yunsite,项目名称:nuomituan,代码行数:25,代码来源:IndexAction.class.php

示例2: displayMenu

/**
 * 递归处理菜单
 * @param $menu array 需要处理的菜单
 * @return array 处理完成
 * 
 */
function displayMenu($menu, $son = true)
{
    $html = '';
    if ($son) {
        $html .= "<ul>\n";
    } else {
        $html .= "<ul class=\"tree treeFolder expand\" onclick='kkk'>\n";
    }
    foreach ($menu as $value) {
        $target = "navTab";
        if ($value['dialog']) {
            $target = "dialog";
        }
        $url = __APP__ . $value['url'];
        if ($value['url'] != '/') {
            $html .= "<li>\n<a target=\"{$target}\" rel=\"ac_{$value['id']}\" href=\"{$url}\"> {$value['title']} </a>\n";
        } else {
            $html .= "<li>\n<a>{$value['title']} </a>\n";
        }
        if (count($value['menu'])) {
            $html .= displayMenu($value['menu']);
        }
        $html .= "</li>\n";
    }
    "";
    $html .= "</ul>\n";
    return $html;
}
开发者ID:yunsite,项目名称:nuomituan,代码行数:34,代码来源:common.php

示例3: displayMenu

?>
/images/puckcast-icon.png" alt="Puckcast" title="Puckcast" width="34" height="34" border="0" ></a>
												
			</div>
-->
			
		<!--END .header-->
		</div>
		
		<!-- BEGIN #primary-nav -->
		<div id="primary-nav-container">
        
        			<div id="primary-nav" class="rounded">
                    <div style="width:740px; float:left">
<?php 
displayMenu(1, 2);
?>
					</div>
					<div align="right" style="width:200px; float:right;padding-top:12px" class="header_login_btn_box">
<?php 
global $userdata;
get_currentuserinfo();
if (is_user_logged_in()) {
    echo "Hi <a href='/wp-admin/profile.php'>" . $userdata->user_login . "</a>\r\n\t\t\t\t\t\t\t\t / \r\n\t\t\t\t\t\t\t\t<a href='" . wp_logout_url(get_permalink()) . "'>Logout</a>";
} else {
    echo "<a href='/wp-login.php?redirect_to=" . urlencode(get_permalink()) . "'>Login</a> | \r\n\t\t\t\t\t\t\t\t\t<a href='/wp-login.php?action=register'>Sign Up</a>\r\n\t\t\t\t\t\t\t\t\t";
}
?>
						
					</div>
        </div>
开发者ID:srolland,项目名称:dev,代码行数:31,代码来源:header.php

示例4: PLG_replaceTags


//.........这里部分代码省略.........
                        if (isset($_USER['uid']) && $_USER['uid'] > 1) {
                            $result = DB_query("SELECT maxstories,tids,aids FROM {$_TABLES['userindex']} WHERE uid = {$_USER['uid']}");
                            $U = DB_fetchArray($result);
                        } else {
                            $U['maxstories'] = 0;
                            $U['aids'] = '';
                            $U['tids'] = '';
                        }
                        $sql = " (date <= NOW()) AND (draft_flag = 0)";
                        if (empty($topic)) {
                            $sql .= COM_getLangSQL('tid', 'AND', 's');
                        }
                        $sql .= COM_getPermSQL('AND', 0, 2, 's');
                        if (!empty($U['aids'])) {
                            $sql .= " AND s.uid NOT IN (" . str_replace(' ', ",", $U['aids']) . ") ";
                        }
                        if (!empty($U['tids'])) {
                            $sql .= " AND s.tid NOT IN ('" . str_replace(' ', "','", $U['tids']) . "') ";
                        }
                        $sql .= COM_getTopicSQL('AND', 0, 's') . ' ';
                        $userfields = 'u.uid, u.username, u.fullname';
                        $msql = "SELECT STRAIGHT_JOIN s.*, UNIX_TIMESTAMP(s.date) AS unixdate, " . 'UNIX_TIMESTAMP(s.expire) as expireunix, ' . $userfields . ", t.topic, t.imageurl " . "FROM {$_TABLES['stories']} AS s, {$_TABLES['users']} AS u, " . "{$_TABLES['topics']} AS t WHERE s.sid = '" . $autotag['parm1'] . "' AND (s.uid = u.uid) AND (s.tid = t.tid) AND" . $sql;
                        $result = DB_query($msql);
                        $nrows = DB_numRows($result);
                        if ($A = DB_fetchArray($result)) {
                            $story = new Story();
                            $story->loadFromArray($A);
                            $linktext = STORY_renderArticle($story, 'y');
                        }
                        $content = str_replace($autotag['tagstr'], $linktext, $content);
                    }
                    if ($autotag['tag'] == 'showblock') {
                        $blockName = COM_applyBasicFilter($autotag['parm1']);
                        $result = DB_query("SELECT * FROM {$_TABLES['blocks']} WHERE name = '" . DB_escapeString($blockName) . "'" . COM_getPermSQL('AND'));
                        if (DB_numRows($result) > 0) {
                            $skip = 0;
                            $B = DB_fetchArray($result);
                            $template = '';
                            $side = '';
                            $px = explode(' ', trim($autotag['parm2']));
                            if (is_array($px)) {
                                foreach ($px as $part) {
                                    if (substr($part, 0, 9) == 'template:') {
                                        $a = explode(':', $part);
                                        $template = $a[1];
                                        $skip++;
                                    } elseif (substr($part, 0, 5) == 'side:') {
                                        $a = explode(':', $part);
                                        $side = $a[1];
                                        $skip++;
                                        break;
                                    }
                                }
                                if ($skip != 0) {
                                    if (count($px) > $skip) {
                                        for ($i = 0; $i < $skip; $i++) {
                                            array_shift($px);
                                        }
                                        $caption = trim(implode(' ', $px));
                                    } else {
                                        $caption = '';
                                    }
                                }
                            }
                            if ($template != '') {
                                $_BLOCK_TEMPLATE[$blockName] = 'blockheader-' . $template . '.thtml,blockfooter-' . $template . '.thtml';
                            }
                            if ($side == 'left') {
                                $B['onleft'] = 1;
                            } else {
                                if ($side == 'right') {
                                    $B['onleft'] = 0;
                                }
                            }
                            $linktext = COM_formatBlock($B);
                            $content = str_replace($autotag['tagstr'], $linktext, $content);
                        } else {
                            $content = str_replace($autotag['tagstr'], '', $content);
                        }
                    }
                    if ($autotag['tag'] == 'menu') {
                        $menu = '';
                        $menuID = trim($autotag['parm1']);
                        $menuHTML = displayMenu($menuID);
                        $content = str_replace($autotag['tagstr'], $menuHTML, $content);
                    }
                    if (isset($_AUTOTAGS[$autotag['tag']])) {
                        $content = autotags_autotag('parse', $content, $autotag);
                    }
                } else {
                    if (function_exists($function) and (empty($plugin) or $plugin == $autotag['module'])) {
                        $content = $function('parse', $content, $autotag);
                    }
                }
            }
        }
        $recursionCount--;
    }
    return $content;
}
开发者ID:spacequad,项目名称:glfusion,代码行数:101,代码来源:lib-plugins.php

示例5: uiSettings

function uiSettings()
{
    global $cfg;
    // load global settings + overwrite per-user settings
    loadSettings();
    // display
    DisplayHead("Administration - UI Settings");
    // Admin Menu
    displayMenu();
    // Main Settings Section
    ?>
	<div align="center">
	<table width="100%" border="1" bordercolor="<?php 
    echo $cfg["table_admin_border"];
    ?>
" cellpadding="2" cellspacing="0" bgcolor="<?php 
    echo $cfg["table_data_bg"];
    ?>
">
	<tr><td bgcolor="<?php 
    echo $cfg["table_header_bg"];
    ?>
" background="themes/<?php 
    echo $cfg["theme"];
    ?>
/images/bar.gif">
	<img src="images/properties.png" width="18" height="13" border="0">&nbsp;&nbsp;<font class="title">UI Settings</font>
	</td></tr><tr><td align="center">

	<div align="center">

		 <table cellpadding="5" cellspacing="0" border="0" width="100%">
			<form name="theForm" action="admin.php?op=updateUiSettings" method="post">



		<tr><td colspan="2" align="center" bgcolor="<?php 
    echo $cfg["table_header_bg"];
    ?>
"><strong>Index-Page</strong></td></tr>

		<tr>
			<td align="left" width="350" valign="top"><strong>Select index-page</strong><br>
			Select the index-Page.
			</td>
			<td valign="top">
				<?php 
    printIndexPageSelectForm();
    ?>
			</td>
		</tr>

		<tr>
			<td align="left" width="350" valign="top"><strong>index-page settings</strong><br>
			Select the columns in transfer-list on index-Page.<br>(only for b4rt-index-page)
			</td>
			<td valign="top">
				<?php 
    printIndexPageSettingsForm();
    ?>
			</td>
		</tr>

		<tr>
			<td align="left" width="350" valign="top"><strong>Width</strong><br>
			Specify the width of the index-page. (780):
			</td>
			<td valign="bottom">
				<input name="ui_dim_main_w" type="Text" maxlength="5" value="<?php 
    echo $cfg["ui_dim_main_w"];
    ?>
" size="5">
			</td>
		</tr>
		<tr>
			<td align="left" width="350" valign="top"><strong>Display Links</strong><br>
			Display Links on the index-page. (true):
			</td>
			<td valign="bottom">
				<select name="ui_displaylinks">
						<option value="1">true</option>
						<option value="0" <?php 
    if (!$cfg["ui_displaylinks"]) {
        echo "selected";
    }
    ?>
>false</option>
				</select>
			</td>
		</tr>
		<tr>
			<td align="left" width="350" valign="top"><strong>Display Users</strong><br>
			Display Users on the index-page. (true):
			</td>
			<td valign="bottom">
				<select name="ui_displayusers">
						<option value="1">true</option>
						<option value="0" <?php 
    if (!$cfg["ui_displayusers"]) {
        echo "selected";
//.........这里部分代码省略.........
开发者ID:BackupTheBerlios,项目名称:tf-b4rt-svn,代码行数:101,代码来源:admin.php

示例6: displayMenu

/**
 * Displays the menu form fields.
 *
 * @param FolderParser $folderParser folderParser object
 * @param string $folderId folder id
 */
function displayMenu($folderParser, $folderId)
{
    global $runSuites;
    $folder = $folderParser->getFolder($folderId);
    if (isset($folder['subfolders'])) {
        foreach ($folder['subfolders'] as $subId) {
            $subfolder = $folderParser->getFolder($subId);
            $dir = str_replace(ROOT_DIR, '', $folder);
            // set the display state:
            $display = 'none';
            $arrow = 'collapsed.png';
            foreach ($runSuites as $suiteId => $tests) {
                if (strstr($suiteId, $dir)) {
                    $display = 'block';
                    $arrow = 'expanded.png';
                    break;
                }
            }
            printf('<div class="groupName" onclick="toggleGroup(\'%s\')"><img id="arrow_%s" class="arrow" src="images/%s"/></span> %s</div>', $subId, $subId, $arrow, basename($subfolder['path']));
            printf('<div class="group" id="%s" style="display: %s">', $subId, $display);
            displayMenu($folderParser, $subId);
            printf('</div>');
        }
    }
    if (isset($folder['suites'])) {
        foreach ($folder['suites'] as $suiteId) {
            $suite = $folderParser->getSuite($suiteId);
            // suite name is the short file name (with suffix detached)
            $suiteName = str_replace(TEST_SUFFIX . '.php', '', basename($suite['path']));
            // checked state
            $checked = in_array($suiteId, $runSuites);
            // Main box:
            printf('<div class="suiteSelect"
				onclick="setCheckBox(\'%s\'); setCheckBoxes(\'%s\', document.getElementById(\'%s\').checked);"
				onmouseover="toggleTests(\'%s\', event, true);"
				onmouseout="toggleTests(\'%s\', event, false);"
				id="suiteSelect_%s"
				>', $suiteId, 'tests_' . $suiteId, $suiteId, $suiteId, $suiteId, $suiteId);
            // checkbox for suite
            printf('<input class="checkbox" onclick="this.checked = !this.checked;" type="checkbox" name="suite" id="%s" value="%s"%s/>', $suiteId, $suiteId, $checked ? ' checked="checked"' : '');
            printf('<span class="checkboxFront%s"></span>', $checked ? 'Set' : 'Unset');
            // arrow for toggling the suite tests box
            printf('<img id="%s" class="arrow_suite" src="" fleoscmouseover="toggleTests(\'%s\', event, true);" fleoscmouseout="toggleTests(\'%s\', event, false);"/>', 'arrow_' . $suiteId, $suiteId, $suiteId);
            printf('<span>');
            if (in_array($suiteId, $runSuites)) {
                printf('<a href="#a_%s">%s</a>', $suiteId, $suiteName);
            } else {
                echo $suiteName;
            }
            echo '</span>';
            echo '</div>';
            // Display the suite tests box:
            // Set height and width of the tests box
            $height = count($suite['tests']) * 17 + 43;
            $width = max(maxLength($suite['tests']) * 8, 175);
            // tests box
            printf('<div id="%s" class="testSelectClosed" style="width: ' . $width . 'px; height: ' . $height . 'px;" onmouseout="toggleTests(\'%s\', event, false);">', 'tests_' . $suiteId, $suiteId);
            foreach ($suite['tests'] as $test) {
                $testId = $suiteId . '@' . $test;
                // used the '@' string as delimiter
                // test box
                printf('<div class="testSelect" onclick="setCheckBox(\'%s\'); setCheckBoxSuite(\'%s\');">', $testId, $suiteId);
                // checkbox for test
                printf('<input class="checkbox" onclick="this.checked = !this.checked;" type="checkbox" name="runSuites[%s][]" id="%s" value="%s"%s/>', $suiteId, $testId, $test, $checked ? ' checked="checked"' : '');
                printf('<span class="checkboxFront%s"></span>', $checked ? 'Set' : 'Unset');
                echo $test;
                echo '</div>';
            }
            // buttons for select and clear all
            printf('<p style="text-align: center;"><input class="button" style="width: 80px;" type="button" onclick="toggleAllTests(%s,%s);" value="%s"/>', "'{$suiteId}'", "false", CLEAR_ALL_LABEL);
            echo '&nbsp;';
            printf('<input class="button" style="width: 80px;" type="button" onclick="toggleAllTests(%s,%s);" value="%s"/></p>', "'{$suiteId}'", "true", SELECT_ALL_LABEL);
            echo '&nbsp;';
            echo '</div>';
        }
    }
    // buttons for select and clear all
    printf('<p><input class="button" style="width: 80px;" type="button" onclick="setCheckBoxes(%s,%s)" value="%s"/>', "'{$folderId}'", "false", CLEAR_ALL_LABEL);
    echo '&nbsp;';
    printf('<input class="button" style="width: 80px;" type="button" onclick="setCheckBoxes(%s,%s)" value="%s"/></p>', "'{$folderId}'", "true", SELECT_ALL_LABEL);
    echo '&nbsp;';
}
开发者ID:hthetiot,项目名称:basezf,代码行数:88,代码来源:functions.php

示例7: displayMenu

<script>
	ad_tile=ad_tile+1;
	document.write('\<SCRIPT language=\"JavaScript1.1\" SRC=\"http:\/\/ad.ca.doubleclick.net\/N3081\/adj\/'+ad_adsite+ad_path+';'+ad_loc.leaderboard+ad_sz.leaderboard+'tile='+ad_tile+';'+ad_dcopt.leaderboard+ad_nk+ad_pr+ad_ck+ad_sck+ad_page+ad_cnt+ad_kv+ad_kw+ad_ord+'?\">\<\/SCRIPT>');
</script>
<noscript>
	<a TARGET="_top" HREF="http://ad.ca.doubleclick.net/N3081/jump/mg_habsio.com/noscript;loc=theTop;loc=top;sz=468x60,728x90;tile=1;dcopt=ist;ord=47159745?">
	<IMG ALIGN="TOP" BORDER="0" VSPACE="0" HSPACE="0" WIDTH="468" HEIGHT="60" SRC="http://ad.ca.doubleclick.net/N3081/ad/mg_habsio.com/noscript;loc=theTop;loc=top;sz=468x60,728x90;tile=1;dcopt=ist;ord=47159745?"></a>
</noscript><!-- End of leaderboard -->
</div>
			
		<!--END .header-->
		</div>
		
		<!-- BEGIN #primary-nav -->
		<div id="primary-nav-container">
        
        			<div id="primary-nav" class="rounded">
                    <div style="width:740px; float:left">
<?php 
displayMenu(2, 2);
?>
					</div>
            <div align="right" style="width:200px; float:left;;padding-top:12px"><a href="http://www.montrealgazette.com" target="_blank"><img src="/wp-content/themes/deadline/images/gazette-logo.png" alt="The Montreal Gazette" border="0" /></a>
            	</div>
        </div>
		</div>
		<!-- END #primary-nav -->
		<!--BEGIN #content -->
		<div id="content-container">
		<div id="content" class="clearfix">
	
开发者ID:srolland,项目名称:dev,代码行数:30,代码来源:header-back02.php

示例8: searchSettings

function searchSettings()
{
    global $cfg;
    include_once "AliasFile.php";
    include_once "RunningTorrent.php";
    include_once "searchEngines/SearchEngineBase.php";
    DisplayHead("Administration - Search Settings");
    // Admin Menu
    displayMenu();
    // Main Settings Section
    echo "<div align=\"center\">";
    echo "<table width=\"100%\" border=1 bordercolor=\"" . $cfg["table_admin_border"] . "\" cellpadding=\"2\" cellspacing=\"0\" bgcolor=\"" . $cfg["table_data_bg"] . "\">";
    echo "<tr><td bgcolor=\"" . $cfg["table_header_bg"] . "\" background=\"themes/" . $cfg["theme"] . "/images/bar.gif\">";
    echo "<img src=\"images/properties.png\" width=18 height=13 border=0>&nbsp;&nbsp;<font class=\"title\">Search Settings</font>";
    echo "</td></tr><tr><td align=\"center\">";
    ?>
    <div align="center">

        <table cellpadding="5" cellspacing="0" border="0" width="100%">
        <form name="theForm" action="admin.php?op=searchSettings" method="post">
        <tr>
            <td align="right" width="350" valign="top"><strong>Select Search Engine</strong><br>
            </td>
            <td valign="top">
<?php 
    $searchEngine = getRequestVar('searchEngine');
    if (empty($searchEngine)) {
        $searchEngine = $cfg["searchEngine"];
    }
    echo buildSearchEngineDDL($searchEngine, true);
    ?>
            </td>
        </tr>
        </form>
        </table>

        <table cellpadding="0" cellspacing="0" border="0" width="100%">
        <tr><td>
<?php 
    if (is_file('searchEngines/' . $searchEngine . 'Engine.php')) {
        include_once 'searchEngines/' . $searchEngine . 'Engine.php';
        $sEngine = new SearchEngine(serialize($cfg));
        if ($sEngine->initialized) {
            echo "<table width=\"100%\" border=1 bordercolor=\"" . $cfg["table_admin_border"] . "\" cellpadding=\"2\" cellspacing=\"0\" bgcolor=\"" . $cfg["table_data_bg"] . "\"><tr>";
            echo "<td bgcolor=\"" . $cfg["table_header_bg"] . "\" background=\"themes/" . $cfg["theme"] . "/images/bar.gif\"><img src=\"images/properties.png\" width=18 height=13 border=0>&nbsp;&nbsp;<font class=\"title\">" . $sEngine->mainTitle . " Search Settings</font></td>";
            echo "</tr></table></td>";
            echo "<form name=\"theSearchEngineSettings\" action=\"admin.php?op=updateSearchSettings\" method=\"post\">\n";
            echo "<input type=\"hidden\" name=\"searchEngine\" value=\"" . $searchEngine . "\">";
            ?>
            </td>
        </tr>
        <tr>
            <td>

        <table cellpadding="5" cellspacing="0" border="0" width="100%">
        <tr>
            <td align="left" width="350" valign="top"><strong>Search Engine URL:</strong></td>
            <td valign="top">
                <?php 
            echo "<a href=\"http://" . $sEngine->mainURL . "\" target=\"_blank\">" . $sEngine->mainTitle . "</a>";
            ?>
            </td>
        </tr>
        <tr>
            <td align="left" width="350" valign="top"><strong>Search Module Author:</strong></td>
            <td valign="top">
                <?php 
            echo $sEngine->author;
            ?>
            </td>
        </tr>
        <tr>
            <td align="left" width="350" valign="top"><strong>Version:</strong></td>
            <td valign="top">
                <?php 
            echo $sEngine->version;
            ?>
            </td>
        </tr>
<?php 
            if (strlen($sEngine->updateURL) > 0) {
                ?>
        <tr>
            <td align="left" width="350" valign="top"><strong>Update Location:</strong></td>
            <td valign="top">
                <?php 
                echo "<a href=\"" . $sEngine->updateURL . "\" target=\"_blank\">Check for Update</a>";
                ?>
            </td>
        </tr>
<?php 
            }
            if (!$sEngine->catFilterName == '') {
                ?>
        <tr>
            <td align="left" width="350" valign="top"><strong>Search Filter:</strong><br>
            Select the items that you DO NOT want to show in the torrent search:
            </td>
            <td valign="top">
<?php 
//.........这里部分代码省略.........
开发者ID:aungthiha-richard,项目名称:torrentflux,代码行数:101,代码来源:admin.php

示例9: displayMenu

    ?>
</a>
    </li>
    <li class="menuReload">
        <a href="#menuReload"><?php 
    echo RESET_TESTER_LABEL;
    ?>
</a>
    </li>
</ul>
<!-- Main menu and form -->
<div id="menu">
<form id="menuForm" method="post" action="./">
<?php 
    if ($folderParser->getRootFolderId() !== 0) {
        displayMenu($folderParser, $folderParser->getRootFolderId());
    } else {
        echo 'No tests found. Please check out your config file.<br /><br />';
    }
    ?>
<input type="hidden" name="keepOpen" id="keepOpen" value="<?php 
    echo $keepOpen;
    ?>
"/>
<input type="hidden" name="coverage" id="coverage" value="false" />
<input type="hidden" name="reset" id="reset" value="false" />
<div>
    <input class="button" style="width: 80px;" type="button" name="action" id="submitForm" value="<?php 
    echo RUN_SELECTED_LABEL;
    ?>
" onclick="runTests()" />
开发者ID:highfidelity,项目名称:love,代码行数:31,代码来源:index.php

示例10: displayMenu

                d.appendChild(a.canvas);
                container.appendChild(d);
                a.canvas.style.marginTop = (150 - a.fullHeight) / 2 + 'px';
                a.canvas.style.marginLeft = (150 - a.fullWidth) / 2 + 'px';
                a.play();
        }

    </script> 
    
    <div id="animation" ></div>
        <div class="content_container">
            <div class="container_12 content_highlight">
                <!--Left Menu Section -->
                <div class="grid_4">
                    <?php 
displayMenu($config);
?>
                </div>

                <!--Center Content Section -->
                <div class="grid_8">
                    <!--Content Login Section -->
                    <div class="login">
                        <?php 
displayLogin($config);
?>
                        <div class="clear"></div>
                    </div> 

                    <div class="divider"></div>
开发者ID:rwgt0su,项目名称:web-time-sheet,代码行数:30,代码来源:wts_index.php

示例11: COM_siteFooter


//.........这里部分代码省略.........
        $dimension = $imgInfo[3];
        $L->set_var('site_name', $_CONF['site_name']);
        $site_logo = $_CONF['site_url'] . '/images/' . $_LOGO['logo_name'];
        $L->set_var('site_logo', $site_logo);
        $L->set_var('dimension', $dimension);
        if ($imgInfo[1] != 100) {
            $delta = 100 - $imgInfo[1];
            $newMargin = $delta;
            $L->set_var('delta', 'style="padding-top:' . $newMargin . 'px;"');
        } else {
            $L->set_var('delta', '');
        }
        if ($_LOGO['display_site_slogan']) {
            $L->set_var('site_slogan', $_CONF['site_slogan']);
        }
        $L->parse('output', 'logo');
        $theme->set_var('logo_block', $L->finish($L->get_var('output')));
    } else {
        if ($_LOGO['use_graphic_logo'] == 0) {
            $L = new Template($_CONF['path_layout']);
            $L->set_file(array('logo' => 'logo-text.thtml'));
            $L->set_var('site_name', $_CONF['site_name']);
            if ($_LOGO['display_site_slogan']) {
                $L->set_var('site_slogan', $_CONF['site_slogan']);
            }
            $L->parse('output', 'logo');
            $theme->set_var('logo_block', $L->finish($L->get_var('output')));
        } else {
            $theme->set_var('logo_block', '');
        }
    }
    $theme->set_var('site_logo', $_CONF['layout_url'] . '/images/logo.' . $_IMAGE_TYPE);
    $theme->set_var(array('lang_login' => $LANG01[58], 'lang_myaccount' => $LANG01[48], 'lang_logout' => $LANG01[35], 'lang_newuser' => $LANG12[3]));
    $menu_navigation = displayMenu('navigation');
    $menu_footer = displayMenu('footer');
    $menu_header = displayMenu('header');
    $theme->set_var(array('menu_navigation' => $menu_navigation, 'menu_footer' => $menu_footer, 'menu_header' => $menu_header, 'st_hmenu' => $menu_navigation, 'st_footer_menu' => $menu_footer, 'st_header_menu' => $menu_header));
    $lblocks = '';
    /* Check if an array has been passed that includes the name of a plugin
     * function or custom function
     * This can be used to take control over what blocks are then displayed
     */
    if (is_array($what)) {
        $function = $what[0];
        if (function_exists($function)) {
            $lblocks = $function($what[1], 'left');
        } else {
            $lblocks = COM_showBlocks('left', $topic);
        }
    } else {
        if ($what != 'none') {
            // Now show any blocks -- need to get the topic if not on home page
            $lblocks = COM_showBlocks('left', $topic);
        }
    }
    /* Now build footer */
    if (empty($lblocks)) {
        $theme->set_var('left_blocks', '');
        $theme->set_var('glfusion_blocks', '');
    } else {
        $theme->set_var('glfusion_blocks', $lblocks);
    }
    // Do variable assignments
    $theme->set_var('site_mail', "mailto:{$_CONF['site_mail']}");
    $theme->set_var('site_slogan', $_CONF['site_slogan']);
    $rdf = substr_replace($_CONF['rdf_file'], $_CONF['site_url'], 0, strlen($_CONF['path_html']) - 1) . LB;
开发者ID:NewRoute,项目名称:glfusion,代码行数:67,代码来源:lib-common.php

示例12: displayReceipt

}
function displayReceipt()
{
    global $type, $size, $pizzaPrices;
    $price = $pizzaPrices[$type][$size];
    $tax = 0.0975 * (double) $price;
    $total = (double) $price + (double) $tax;
    $output = "<h1 >Thank you. Here is your receipt.</h1>\r\n                <table class='center'>\r\n                  <tr><td>\r\n                    <table>\r\n                    <tr><td class='center'>Kind of pizza</td><td class='center'>{$type}</td></tr>\r\n                    <tr><td class='center'>Size</td><td class='center'>{$size}</td></tr>\r\n                    <tr><td class='center'>Price</td><td class='center'>\$ " . number_format($price, 2, '.', ',') . "</td></tr>\r\n                    <tr><td class='center'>Tax</td><td class='center'>\$ " . number_format($tax, 2, '.', ',') . "</td></tr>\r\n                    <tr><td class='center'>Total</td><td class='center'>\$ " . number_format($total, 2, '.', ',') . "</td></tr>\r\n                    </table>\r\n                  </td></tr>\r\n                </table></br>\r\n                <form id='myform' method='POST' >\r\n                <h1><button type='submit' name='done'>Click to Pay Bill</button></h1>\r\n                </form>";
    print $output;
}
if (!isset($_SESSION["placeAnOrder"])) {
    $placeAnOrder = true;
    $_SESSION["placeAnOrder"] = $placeAnOrder;
    setPizzaArray();
    $_SESSION["pizzaPrices"] = $pizzaPrices;
    displayMenu();
    printOrderForm();
} else {
    if ($_SESSION["placeAnOrder"]) {
        global $type, $size;
        $pizzaPrices = $_SESSION["pizzaPrices"];
        $type = $_REQUEST["type"];
        $size = $_REQUEST["size"];
        displayReceipt();
        $placeAnOrder = false;
        $_SESSION["placeAnOrder"] = $placeAnOrder;
    } else {
        echo <<<HERE
                <h1>Thank you for your order!!</h1>
                <h3>Please refresh to continue.</h3>
HERE;
开发者ID:steve402791890,项目名称:CS85,代码行数:31,代码来源:pizzaOrder.php

示例13: loginAnchor

}
if (isset($header)) {
    if ($header) {
        ?>
<div data-role="header" data-theme="a">
<div data-role="controlgroup" data-type="horizontal" class="ui-btn-right" >
<?php 
        echo loginAnchor(null, null, null, null, $register);
        ?>
 </div>
<h1><?php 
        echo $heading;
        ?>
</h1>
<?php 
        echo displayMenu();
        ?>
</div>
<?php 
    } else {
        ?>

<center>
<h1><?php 
        echo $heading;
        ?>
</h1>
</center>
<?php 
    }
} else {
开发者ID:behzad900,项目名称:rspsms,代码行数:31,代码来源:header.php

示例14: displayMenu

$html .= '<span class="title">Insalata Piccolo</span><br />' . "\n";
$html .= '<span class="descrip">Fresh Garden Salad</span>';
$html .= '</p>';
$html .= '<a href="#menuTitle" class="top">back to menu &uarr;</a>' . "\n";
$html .= '</div>' . "\n";
$html .= '<div class="menuContent" id="speciale">' . "\n";
$html .= '<h5>Piccolo Speciale</h5>' . "\n";
$html .= '<p>';
$html .= '<span class="title">Blackboard Selection</span><br />' . "\n";
$html .= '<span class="descrip">Check out our blackboard for the Chef\'s specials.</span>';
$html .= '</p>';
$html .= '<a href="#menuTitle" class="top">back to menu &uarr;</a>' . "\n";
$html .= '</div>';
$html .= '<div class="menuContent" id="pasta">' . "\n";
$html .= '<h5>Pasta</h5>' . "\n";
$html .= displayMenu($pasta);
$html .= '</div>';
$html .= '<div class="menuContent" id="dolci">' . "\n";
$html .= '<h5>Dolci</h5>' . "\n";
$html .= '<p>';
$html .= '<span class="title">Blackboard Selection</span><br />' . "\n";
$html .= '<span class="descrip">Check out our blackboard for dessert specials.</span>';
$html .= '</p>';
$html .= '<a href="#menuTitle" class="top">back to menu &uarr;</a>' . "\n";
$html .= '</div>';
$html .= '<div class="menuContent" id="bevande">' . "\n";
$html .= '<h5>Bevande</h5>' . "\n";
$html .= displayDrinks($bevande);
$html .= '</div>';
$html .= '<div class="menuContent" id="vino">' . "\n";
$html .= '<h5>Vino</h5>' . "\n";
开发者ID:niki-b,项目名称:piccolo-trattoria,代码行数:31,代码来源:index.php

示例15: runWWWVersion


//.........这里部分代码省略.........
                    echo "<p>Please check your request and try again.</p>";
                    endHTML(true);
                }
            case 'setForceChangePassword':
                if ($_POST['mode'] == 'set') {
                    startHTML();
                    setUserMustChangePassword($gapps, true, $_POST['user']);
                    endHTML(true);
                } elseif ($_POST['mode'] == 'clear') {
                    startHTML();
                    clearUserMustChangePassword($gapps, true, $_POST['user']);
                    endHTML(true);
                } else {
                    header('HTTP/1.1 400 Bad Request');
                    startHTML();
                    echo "<h2>Invalid mode.</h2>\n";
                    echo "<p>Please check your request and try again.</p>";
                    endHTML(true);
                }
            case 'deleteUser':
                startHTML();
                deleteUser($gapps, true, $_POST['user']);
                endHTML(true);
            case 'createNickname':
                startHTML();
                createNickname($gapps, true, $_POST['user'], $_POST['nickname']);
                endHTML(true);
            case 'deleteNickname':
                startHTML();
                deleteNickname($gapps, true, $_POST['nickname']);
                endHTML(true);
            case 'createEmailList':
                startHTML();
                createEmailList($gapps, true, $_POST['emailList']);
                endHTML(true);
            case 'deleteEmailList':
                startHTML();
                deleteEmailList($gapps, true, $_POST['emailList']);
                endHTML(true);
            case 'modifySubscription':
                if ($_POST['mode'] == 'subscribe') {
                    startHTML();
                    addRecipientToEmailList($gapps, true, $_POST['recipient'], $_POST['emailList']);
                    endHTML(true);
                } elseif ($_POST['mode'] == 'unsubscribe') {
                    startHTML();
                    removeRecipientFromEmailList($gapps, true, $_POST['recipient'], $_POST['emailList']);
                    endHTML(true);
                } else {
                    header('HTTP/1.1 400 Bad Request');
                    startHTML();
                    echo "<h2>Invalid mode.</h2>\n";
                    echo "<p>Please check your request and try again.</p>";
                    endHTML(true);
                }
        }
    }
    // Check for an invalid command. If so, display an error and exit.
    if (!empty($_REQUEST['command'])) {
        header('HTTP/1.1 400 Bad Request');
        startHTML();
        echo "<h2>Invalid command.</h2>\n";
        echo "<p>Please check your request and try again.</p>";
        endHTML(true);
    }
    // If a menu parameter is available, display a submenu.
    if (!empty($_REQUEST['menu'])) {
        switch ($_REQUEST['menu']) {
            case 'user':
                startHTML();
                displayUserMenu();
                endHTML();
            case 'nickname':
                startHTML();
                displayNicknameMenu();
                endHTML();
            case 'emailList':
                startHTML();
                displayEmailListMenu();
                endHTML();
            case 'logout':
                startHTML(false);
                logout();
                endHTML();
            default:
                header('HTTP/1.1 400 Bad Request');
                startHTML();
                echo "<h2>Invalid menu selection.</h2>\n";
                echo "<p>Please check your request and try again.</p>";
                endHTML(true);
        }
    }
    // If we get this far, that means there's nothing to do. Display
    // the main menu.
    // If no command was issued and no menu was selected, display the
    // main menu.
    startHTML();
    displayMenu();
    endHTML();
}
开发者ID:SustainableCoastlines,项目名称:loveyourwater,代码行数:101,代码来源:Gapps.php


注:本文中的displayMenu函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。