本文整理汇总了PHP中mosMenuBar::apply方法的典型用法代码示例。如果您正苦于以下问题:PHP mosMenuBar::apply方法的具体用法?PHP mosMenuBar::apply怎么用?PHP mosMenuBar::apply使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类mosMenuBar
的用法示例。
在下文中一共展示了mosMenuBar::apply方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: _EDIT
/**
* Draws the menu to edit a menu item
*/
function _EDIT($type)
{
global $id;
$hs = '';
if (!$id) {
$cid = mosGetParam($_POST, 'cid', array(0));
$id = $cid[0];
}
$menutype = mosGetParam($_REQUEST, 'menutype', 'mainmenu');
mosMenuBar::startTable();
if (!$id) {
$link = 'index2.php?option=com_menus&menutype=' . $menutype . '&task=new&hidemainmenu=1';
mosMenuBar::back(T_('Back'), $link);
mosMenuBar::spacer();
}
mosMenuBar::save();
mosMenuBar::spacer();
mosMenuBar::apply();
mosMenuBar::spacer();
if ($id) {
// for existing content items the button is renamed `close`
mosMenuBar::cancel('cancel', T_('Close'));
} else {
mosMenuBar::cancel();
}
mosMenuBar::spacer();
mosMenuBar::help($type);
mosMenuBar::endTable();
}
示例2: _EDIT
/**
* Draws the menu to edit a menu item
*/
function _EDIT()
{
global $id;
if (!$id) {
$cid = josGetArrayInts('cid');
$id = $cid[0];
}
$menutype = strval(mosGetParam($_REQUEST, 'menutype', 'mainmenu'));
mosMenuBar::startTable();
if (!$id) {
$link = 'index2.php?option=com_menus&menutype=' . $menutype . '&task=new&hidemainmenu=1&' . josSpoofValue() . '=1';
mosMenuBar::back('Back', $link);
mosMenuBar::spacer();
}
mosMenuBar::save();
mosMenuBar::spacer();
mosMenuBar::apply();
mosMenuBar::spacer();
if ($id) {
// for existing content items the button is renamed `close`
mosMenuBar::cancel('cancel', 'Close');
} else {
mosMenuBar::cancel();
}
mosMenuBar::spacer();
mosMenuBar::help('screen.menus.edit');
mosMenuBar::endTable();
}
示例3: _EDIT
/**
* Draws the menu for Editing an existing module
*/
function _EDIT()
{
global $id;
mosMenuBar::startTable();
mosMenuBar::save();
mosMenuBar::spacer();
mosMenuBar::apply();
mosMenuBar::spacer();
if ($id) {
// for existing content items the button is renamed `close`
mosMenuBar::cancel('cancel', T_('Close'));
} else {
mosMenuBar::cancel();
}
mosMenuBar::spacer();
if ($GLOBALS['task'] == 'new') {
mosMenuBar::help('new');
} else {
if ($_POST) {
$cid = (int) $GLOBALS['cid'][0];
} else {
$cid = (int) $_GET['id'];
}
$database =& mamboDatabase::getInstance();
$database->setQuery('select element from #__mambots where id = ' . $cid);
$result = $database->loadResult();
mosMenuBar::help($result ? $result : 'edit');
}
mosMenuBar::endTable();
}
示例4: _Announcement
/**
* Renders the toolbar for the announcment controller
*/
function _Announcement()
{
mosMenuBar::startTable();
mosMenuBar::apply('apply');
mosMenuBar::help('ccevents.help.html');
mosMenuBar::endTable();
}
示例5: _EDIT
/**
* Draws the menu for Editing an existing category
* @param int The published state (to display the inverse button)
*/
function _EDIT()
{
global $id;
mosMenuBar::startTable();
mosMenuBar::media_manager();
mosMenuBar::spacer();
mosMenuBar::save();
mosMenuBar::spacer();
mosMenuBar::apply();
mosMenuBar::spacer();
if ($id) {
// for existing content items the button is renamed `close`
mosMenuBar::cancel('cancel', T_('Close'));
} else {
mosMenuBar::cancel();
}
mosMenuBar::spacer();
$section = '';
if (strstr($GLOBALS['section'], 'com_contact')) {
$section = 'contact.';
}
if (strstr($GLOBALS['section'], 'com_newsfeeds')) {
$section = 'newsfeeds.';
}
if (strstr($GLOBALS['section'], 'com_weblinks')) {
$section = 'weblinks.';
}
if ($GLOBALS['task'] == 'new') {
mosMenuBar::help($section . 'new');
} else {
mosMenuBar::help($section . 'edit');
}
mosMenuBar::endTable();
}
示例6: _EDIT
/**
* Draws the menu for Editing an existing module
*/
function _EDIT($cur_template, $publish)
{
global $id;
mosMenuBar::startTable();
?>
<td>
<a class="toolbar" href="#" onClick="if (typeof document.adminForm.content == 'undefined') { alert('A pré-visualização apenas funciona para `novos´ módulos.'); } else { var content = document.adminForm.content.value; content = content.replace('#', ''); var title = document.adminForm.title.value; title = title.replace('#', ''); window.open('popups/modulewindow.php?title=' + title + '&content=' + content + '&t=<?php
echo $cur_template;
?>
', 'win1', 'status=no,toolbar=no,scrollbars=auto,titlebar=no,menubar=no,resizable=yes,width=200,height=400,directories=no,location=no'); }" >
<img src="images/preview_f2.png" alt="Pré-visualizar" border="0" name="preview" align="middle">
Visualizar</a>
</td>
<?php
mosMenuBar::spacer();
mosMenuBar::save();
mosMenuBar::spacer();
mosMenuBar::apply();
mosMenuBar::spacer();
if ($id) {
// for existing content items the button is renamed `close`
mosMenuBar::cancel('cancel', 'Sair');
} else {
mosMenuBar::cancel();
}
mosMenuBar::spacer();
mosMenuBar::help('screen.modules.edit');
mosMenuBar::endTable();
}
示例7: _EDIT
function _EDIT()
{
global $id;
mosMenuBar::startTable();
mosMenuBar::preview('contentwindow', true);
mosMenuBar::spacer();
mosMenuBar::media_manager();
mosMenuBar::spacer();
mosMenuBar::save();
mosMenuBar::spacer();
mosMenuBar::apply();
mosMenuBar::spacer();
if ($id) {
// for existing content items the button is renamed `close`
mosMenuBar::cancel('cancel', T_('Close'));
} else {
mosMenuBar::cancel();
}
mosMenuBar::spacer();
if ($GLOBALS['task'] == 'new') {
mosMenuBar::help('new');
} else {
mosMenuBar::help('edit');
}
mosMenuBar::endTable();
}
示例8: EDIT_ITEM
/**
* Draws the menu for edit list
*/
function EDIT_ITEM()
{
mosMenuBar::startTable();
mosMenuBar::save("save");
mosMenuBar::spacer();
mosMenuBar::apply("apply");
mosMenuBar::spacer();
mosMenuBar::cancel("cancel");
mosMenuBar::endTable();
}
示例9: _EDIT
function _EDIT()
{
global $id, $cid, $priTask, $subTask;
mosMenuBar::startTable();
mosMenuBar::spacer();
mosMenuBar::save($priTask . '.save');
mosMenuBar::spacer();
mosMenuBar::apply($priTask . '.apply');
mosMenuBar::spacer();
mosMenuBar::cancel($priTask . '.cancel', 'Close');
mosMenuBar::endTable();
}
示例10: _DEFAULT
public static function _DEFAULT()
{
mosMenuBar::startTable();
mosMenuBar::save();
mosMenuBar::spacer();
mosMenuBar::apply();
mosMenuBar::spacer();
mosMenuBar::cancel();
mosMenuBar::spacer();
mosMenuBar::help('screen.config');
mosMenuBar::endTable();
}
示例11: _DEFAULT
function _DEFAULT()
{
mosMenuBar::startTable();
mosMenuBar::save();
mosMenuBar::spacer();
mosMenuBar::apply();
mosMenuBar::spacer();
mosMenuBar::cancel();
mosMenuBar::spacer();
mosMenuBar::help('main');
mosMenuBar::endTable();
}
示例12: _EDIT
public static function _EDIT()
{
mosMenuBar::startTable();
mosMenuBar::preview('contentwindow', true);
mosMenuBar::spacer();
mosMenuBar::media_manager();
mosMenuBar::spacer();
mosMenuBar::save();
mosMenuBar::spacer();
mosMenuBar::apply();
mosMenuBar::spacer();
mosMenuBar::cancel();
mosMenuBar::spacer();
mosMenuBar::help('screen.staticcontent.edit');
mosMenuBar::endTable();
}
示例13: _CONFIG
function _CONFIG()
{
if (!defined('_JEXEC')) {
mosMenuBar::startTable();
mosMenuBar::save();
mosMenuBar::spacer();
mosMenuBar::apply();
mosMenuBar::spacer();
mosMenuBar::cancel();
mosMenuBar::endTable();
} else {
JToolBarHelper::save();
JToolBarHelper::apply();
JToolBarHelper::cancel();
}
}
示例14: _EDIT
/**
* Draws the menu to edit a user
*/
public static function _EDIT()
{
global $id;
mosMenuBar::startTable();
mosMenuBar::save();
mosMenuBar::spacer();
mosMenuBar::apply();
mosMenuBar::spacer();
if ($id) {
// for existing content items the button is renamed `close`
mosMenuBar::cancel('cancel', 'Close');
} else {
mosMenuBar::cancel();
}
mosMenuBar::spacer();
mosMenuBar::help('screen.users');
mosMenuBar::endTable();
}
示例15: _EDIT
/**
* Draws the menu for Editing an existing module
*/
function _EDIT($cur_template, $publish)
{
global $id;
mosMenuBar::startTable();
?>
<td><a class="toolbar" href="#" onClick="if (typeof document.adminForm.content == 'undefined') { alert('<?php
echo T_('You can only preview typed modules.');
?>
'); } else { var content = document.adminForm.content.value; content = content.replace('#', ''); var title = document.adminForm.title.value; title = title.replace('#', ''); window.open('popups/modulewindow.php?title=' + title + '&content=' + content + '&t=<?php
echo $cur_template;
?>
', 'win1', 'status=no,toolbar=no,scrollbars=auto,titlebar=no,menubar=no,resizable=yes,width=200,height=400,directories=no,location=no'); }" onmouseout="MM_swapImgRestore();" onmouseover="MM_swapImage('preview','','images/preview_f2.png',1);"><img src="images/preview.png" alt="<?php
echo T_('Preview');
?>
" border="0" name="preview" align="middle"><br /><?php
echo T_('Preview');
?>
</a></td>
<?php
mosMenuBar::spacer();
mosMenuBar::save();
mosMenuBar::spacer();
mosMenuBar::apply();
mosMenuBar::spacer();
if ($id) {
// for existing content items the button is renamed `close`
mosMenuBar::cancel('cancel', T_('Close'));
} else {
mosMenuBar::cancel();
}
mosMenuBar::spacer();
$result = '';
if ($_POST) {
$cid = (int) $GLOBALS['cid'][0];
} else {
$cid = (int) $_GET['id'];
}
$database =& mamboDatabase::getInstance();
$database->setQuery('select module from #__modules where id = ' . $cid);
$result = substr($database->loadResult(), 4);
mosMenuBar::help($result ? $result : 'edit');
mosMenuBar::endTable();
}