本文整理汇总了PHP中html::button方法的典型用法代码示例。如果您正苦于以下问题:PHP html::button方法的具体用法?PHP html::button怎么用?PHP html::button使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类html
的用法示例。
在下文中一共展示了html::button方法的11个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: getActionLink
public static function getActionLink($params, $linktype = 'image')
{
switch ($linktype) {
case 'button':
$value = $params['text'];
$extra = '';
if (isset($params['extra'])) {
$extra = $params['extra'];
}
$extra .= ' onClick="$.get(' . $params['href'] . '); return false;"';
return html::button($params, $value, $extra);
break;
case 'text':
return '<a id="' . $params['id'] . '" name="' . $params['name'] . '" class="' . $params['class'] . '" href="' . $params['href'] . '">' . $params['text'] . '</a>';
break;
case 'image':
default:
return '<a id="' . $params['id'] . '" name="' . $params['name'] . '" class="' . $params['class'] . '" href="' . $params['href'] . '"><img src="' . $params['image'] . '" class="' . $params['class'] . '" title="' . $params['text'] . '" alt="' . $params['text'] . '"/></a>';
break;
}
}
示例2: Copyright
<?php
/**************************************************
Coppermine 1.5.x Plugin - forum
*************************************************
Copyright (c) 2010 foulu (Le Hoai Phuong), eenemeenemuu
*************************************************
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 3 of the License, or
(at your option) any later version.
********************************************
$HeadURL$
$Revision$
$LastChangedBy$
$Date$
**************************************************/
pageheader($fr_title ? $fr_title : Config::item('fr_title'));
print html::spacer();
print table::open(0);
print table::tds(array(array('text' => $fr_title ? $fr_title : Config::item('fr_title')), array('align' => 'right', 'text' => ($authorizer->is_user() ? html::button('forum.php?c=profile', Lang::item('home.fr_profile')) : '') . NBSP . html::button('forum.php?c=search', Lang::item('home.search')))));
print table::close();
print html::spacer();
print table::open();
print form::hidden('c', 'search');
print table::tds(array(array('class' => 'tableb', 'text' => html::span(forum::nagavitor($nagavitor)))));
print table::close();
print html::spacer();
print $fr_contents;
pagefooter();
示例3: submit
/**
* 表单提交按钮
*
* @param $attrs array 控件参数
* @return string 控件代码
*/
public static function submit($attrs)
{
$attrs['type'] = 'submit';
$attrs['class'] = isset($attrs['class']) ? 'submit ' . $attrs['class'] : 'submit';
$attrs += array('id' => 'submitform', 'value' => zotop::t('提交'));
return html::button($attrs);
}
示例4: Copyright
/**************************************************
Coppermine 1.5.x Plugin - forum
*************************************************
Copyright (c) 2010 foulu (Le Hoai Phuong), eenemeenemuu
*************************************************
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 3 of the License, or
(at your option) any later version.
********************************************
$HeadURL$
$Revision$
$LastChangedBy$
$Date$
**************************************************/
// menu
echo table::open();
echo table::tds(array(array('class' => 'tableb', 'text' => html::button('forum.php?c=admin', Lang::item('admin.home')) . NBSP . html::button('forum.php?c=admin&m=newcat', Lang::item('admin.new_category')) . NBSP . html::button('forum.php?c=admin&m=setting', Lang::item('admin.setting')))));
echo table::close();
echo table::open();
echo form::open('forum.php?c=admin&m=editcat');
echo form::hidden('id', $cat_id);
echo table::td(Lang::item('admin.new_cat'), 2);
if (count($errors) > 0) {
echo table::td(table::error($errors), 2, 'tableh2');
}
echo table::tds(array(array('class' => 'tableb', 'text' => Lang::item('admin.fullname')), array('class' => 'tableb', 'text' => form::text('name', $form['name']))));
echo table::tds(array(array('class' => 'tablef', 'colspan' => '2', 'text' => form::submit(Lang::item('common.modify'), 'submit'))));
echo form::close();
echo table::close();
示例5: updateCart
if(res.data.totalHtml) {
updateCart(new Array(), res.data.totalHtml);
}
if(!res.error) {
jQuery('#toeCoupon').val('');
}
}
});
}
function toeShouCouponsDescription(link) {
var linkPos = jQuery(link).position();
subScreen.show(<?php
echo $this->couponsDescription;
?>
, linkPos.left, linkPos.top);
}
// -->
</script>
<h4 class="cuponTitle"><?php
lang::_e('Enter coupon number:');
?>
</h4>
<?php
echo html::text('coupon', array('attrs' => 'id="toeCoupon"'));
echo html::button(array('value' => lang::_('OK'), 'attrs' => 'onclick="toeApplyCoupon(); return false;" class="tcf_submit couponBtn"'));
?>
<div id="toeCouponsCheckoutMsg"></div>
<!-- <a href="#" onclick="toeShouCouponsDescription(this); return false;"><?php
lang::_e('Where I can get It?');
?>
</a> -->
示例6: array
document.getElementById('pv_subject').innerHTML = datas[0];
document.getElementById('pv_body').innerHTML = datas[1];
});
});
});
-->
</script>
EOT;
echo "<div name=\"preview_area\" id=\"preview_area\" style=\"display: none;\">";
echo table::open();
echo table::td(Lang::item('board.topic_preview'), 1);
echo table::tds(array('class' => 'tableh2', 'id' => 'pv_subject', 'text' => ''));
echo table::tds(array('class' => 'tableb', 'id' => 'pv_body', 'text' => ''));
echo table::close();
echo "</div>";
echo table::open();
echo table::td(Lang::item('topic.new_topic'), 2);
echo form::open('forum.php?c=message&m=edit&id=' . $msg_id, 'editmsg');
if (count($errors) > 0) {
echo table::td(table::error($errors), 2, 'tableh2');
}
echo table::tds(array(array('class' => 'tableb', 'width' => '30%', 'text' => Lang::item('topic.subject')), array('class' => 'tableb', 'width' => '70%', 'text' => form::text('subject', $form['subject']))));
if (Config::item('fr_msg_icons') == 1) {
echo table::tds(array(array('class' => 'tableb', 'text' => Lang::item('topic.message_icon')), array('class' => 'tableb', 'text' => forum::generate_message_icons('icon', $icons, $form['icon']))));
}
echo table::tds(array(array('class' => 'tableb', 'text' => NBSP), array('class' => 'tableb', 'text' => forum::generate_bbcode_tags('editmsg', 'body'))));
echo table::tds(array(array('class' => 'tableb', 'text' => Lang::item('topic.message')), array('class' => 'tableb', 'text' => form::textarea('body', $form['body']))));
echo table::tds(array(array('class' => 'tableb', 'text' => NBSP), array('class' => 'tableb', 'text' => generate_smilies('editmsg', 'body'))));
echo table::tds(array(array('class' => 'tablef', 'text' => NBSP), array('class' => 'tablef', 'text' => form::submit(Lang::item('common.modify'), 'submit') . html::jsbutton('return false;', Lang::item('common.preview'), array('id' => 'preview')) . NBSP . html::button('forum.php?c=board&id=' . $board_id, Lang::item('common.cancel')))));
echo form::close();
echo table::close();
示例7: array
echo table::tds(array(array('class' => 'tableh1', 'width' => '170px', 'text' => html::profile_anchor($message['poster_id'], $message['poster_name'])), array('class' => 'tableh1', 'text' => table::open(2) . table::tds(array(array('text' => html::img($message['icon'], '65%') . NBSP . sprintf(Lang::item('topic.topic_title'), html::b(html::anchor('forum.php?c=message&id=' . $message['id'], $message['name'])), time::decode($message['time']))), array('align' => 'right', 'text' => html::anchor('forum.php?c=message&m=single&id=' . $message['id'], html::b('#' . $message['pos']))))) . table::close())));
echo table::tds(array(array('class' => 'tablef', 'valign' => 'top', 'align' => 'left', 'text' => html::span(sprintf(Lang::item('topic.user_profile'), html::img($message['avatar'], Config::item('fr_avatar_size')), $message['poster_group'], $message['poster_posts'], $message['poster_registed']))), array('class' => 'tableb', 'valign' => 'top', 'text' => forum::format_message($message['post']) . (trim($message['signature']) != '' ? sprintf(Lang::item('topic.signature'), forum::format_message($message['signature'])) : ''))));
echo table::tds(array(array('class' => 'tablef', 'text' => html::button('profile.php?uid=' . $message['poster_id'], Lang::item('topic.profile')) . NBSP), array('class' => 'tablef', 'text' => (function_exists('get_bbcode_tags') ? html::button('forum.php?c=topic&m=reply&id=' . $topic_id . '"e=' . $message['id'], Lang::item('common.quote')) . NBSP : '') . ($authorizer->can_edit_msg($message['id']) ? html::button('forum.php?c=message&m=edit&id=' . $message['id'], Lang::item('common.modify')) . NBSP : '') . ($authorizer->can_delete_msg($message['id']) ? html::jsbutton("button_confirm('" . Lang::item('message.confirm_delete') . "','forum.php?c=message&m=delete&id={$message['id']}');", Lang::item('common.delete')) : ''))));
echo table::close();
}
if (count($messages) == 0) {
echo table::open();
echo table::td(Lang::item('topic.no_message'), 1, 'tableb');
echo table::close();
}
// paging
echo table::open();
echo table::tds(array(array('class' => 'tableb', 'text' => table::open(2) . table::tds(array(array('width' => '70%', 'align' => 'left', 'text' => Lang::item('board.page') . forum::paging($paging)), array('width' => '30%', 'align' => 'right', 'text' => (check_model::can_reply($topic_id) ? html::jsbutton('show_section(\'fastreply\');', Lang::item('topic.fast_reply')) . NBSP . html::button('forum.php?c=topic&m=reply&id=' . $topic_id, Lang::item('topic.reply')) : '') . NBSP . ($authorizer->is_user() ? html::jsbutton("button_confirm('" . ($authorizer->is_notify_topic($topic_id) ? Lang::item('topic.disable_notify') : Lang::item('topic.active_notify')) . "','" . ($authorizer->is_notify_topic($topic_id) ? 'forum.php?c=topic&m=unnotify&id=' . $topic_id : 'forum.php?c=topic&m=notify&id=' . $topic_id) . "');", Lang::item('topic.notify')) . NBSP : '')))) . table::close())));
echo html::spacer();
echo table::open();
echo table::tds(array(array('class' => 'tableb', 'text' => table::open(2) . table::tds(array(array('width' => '66%', 'text' => ($authorizer->can_moderator_topic($topic_id) ? html::button('forum.php?c=topic&m=locked&id=' . $topic_id, $authorizer->is_locked($topic_id) ? Lang::item('topic.unlock_topic') : Lang::item('topic.lock_topic')) . NBSP : '') . ($authorizer->can_moderator_topic($topic_id) ? html::button('forum.php?c=topic&m=sticky&id=' . $topic_id, $authorizer->is_sticky($topic_id) ? Lang::item('topic.unsticky_topic') : Lang::item('topic.sticky_topic')) . NBSP : '') . ($authorizer->can_moderator_topic($topic_id) ? html::jsbutton("button_confirm('" . Lang::item('topic.confirm_delete') . "','forum.php?c=topic&m=delete&id={$topic_id}');", Lang::item('topic.delete_topic')) . NBSP : '') . ($authorizer->can_moderator_topic($topic_id) ? html::button('forum.php?c=topic&m=move&id=' . $topic_id, Lang::item('topic.move_topic')) : '')), array('width' => '33%', 'align' => 'right', 'text' => forum::redirect_box($cbs, $board_id)))) . table::close())));
echo table::close();
echo "<div id=\"fastreply\" style=\"display: none;\">";
echo table::open();
echo form::open('forum.php?c=topic&m=reply&id=' . $topic_id, 'fastreply', 'post');
echo table::td(Lang::item('topic.topic_reply'), 4);
echo table::tds(array(array('class' => 'tableb', 'width' => '30%', 'text' => Lang::item('topic.subject')), array('class' => 'tableb', 'width' => '70%', 'text' => form::text('subject', Lang::item('topic.re') . $topic_name))));
if (Config::item('fr_msg_icons') == 1) {
echo table::tds(array(array('class' => 'tableb', 'text' => Lang::item('topic.message_icon')), array('class' => 'tableb', 'text' => forum::generate_message_icons('icon', $icons, 'icon1'))));
}
echo table::tds(array(array('class' => 'tableb', 'text' => NBSP), array('class' => 'tableb', 'text' => forum::generate_bbcode_tags('fastreply', 'body'))));
echo table::tds(array(array('class' => 'tableb', 'text' => Lang::item('topic.message')), array('class' => 'tableb', 'text' => form::textarea('body'))));
global $CONFIG;
if ($CONFIG['comment_captcha'] == 1 || $CONFIG['comment_captcha'] == 2 && !USER_ID) {
global $lang_common;
print table::tds(array(array('class' => 'tableb', 'text' => $lang_common['confirm']), array('class' => 'tableb', 'text' => '<input type="text" name="confirmCode" size="5" maxlength="5" class="textinput" /><img src="captcha.php" align="middle" border="0" alt="" />')));
示例8: Copyright
<?php
/**************************************************
Coppermine 1.5.x Plugin - forum
*************************************************
Copyright (c) 2010 foulu (Le Hoai Phuong), eenemeenemuu
*************************************************
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 3 of the License, or
(at your option) any later version.
********************************************
$HeadURL$
$Revision$
$LastChangedBy$
$Date$
**************************************************/
echo table::open();
echo table::tds(array(array('class' => 'tableh1', 'width' => '170px', 'text' => html::profile_anchor($message['poster_id'], $message['poster_name'])), array('class' => 'tableh1', 'text' => html::img($message['icon'], '65%') . NBSP . sprintf(Lang::item('topic.topic_title'), html::anchor('forum.php?c=message&m=single&id=' . $message['msg_id'], $message['subject']), time::decode($message['time'])))));
echo table::tds(array(array('class' => 'tablef', 'valign' => 'top', 'align' => 'left', 'text' => html::span(sprintf(Lang::item('topic.user_profile'), html::img($message['avatar'], Config::item('fr_avatar_size')), $message['poster_group'], $message['poster_posts'], $message['poster_registed']))), array('class' => 'tableb', 'valign' => 'top', 'text' => forum::format_message($message['body']) . (trim($message['signature']) != '' ? sprintf(Lang::item('topic.signature'), forum::format_message($message['signature'])) : ''))));
echo table::tds(array(array('class' => 'tablef', 'text' => html::button('profile.php?uid=' . $message['poster_id'], Lang::item('topic.profile')) . NBSP), array('class' => 'tablef', 'text' => ($authorizer->can_edit_msg($message['msg_id']) ? html::button('forum.php?c=message&m=edit&id=' . $message['msg_id'], Lang::item('common.modify')) . NBSP : '') . ($authorizer->can_delete_msg($message['msg_id']) ? html::jsbutton("button_confirm('" . Lang::item('message.confirm_delete') . "','forum.php?c=message&m=delete&id={$message['msg_id']}');", Lang::item('common.delete')) : ''))));
echo table::close();
示例9: Copyright
<?php
/**************************************************
Coppermine 1.5.x Plugin - forum
*************************************************
Copyright (c) 2010 foulu (Le Hoai Phuong), eenemeenemuu
*************************************************
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 3 of the License, or
(at your option) any later version.
********************************************
$HeadURL$
$Revision$
$LastChangedBy$
$Date$
**************************************************/
echo table::open();
echo form::open('forum.php?c=profile&id=' . $user['user_id'], 'profile', 'post', TRUE);
echo table::td(Lang::item('profile.profile_title'), 4);
echo table::td(Lang::item('profile.avatar'), 4, 'tableh2');
echo table::tds(array(array('class' => 'tableb', 'width' => '5%', 'align' => 'center', 'text' => form::radio('avatar_type', 'url', '', $user['fr_avatar'] ? 'url' : '')), array('class' => 'tableb', 'width' => '20%', 'text' => Lang::item('profile.url')), array('class' => 'tableb', 'width' => '50%', 'text' => form::text('fr_avatar_url', $user['fr_avatar'])), array('class' => 'tableb', 'width' => '25%', 'align' => 'center', 'rowspan' => 2, 'text' => !php::is_empty_string($user['fr_avatar']) ? html::img($user['fr_avatar'], Config::item('fr_avatar_size')) . BR . BR . html::button('forum.php?c=profile&m=remove_avatar', Lang::item('profile.remove_avatar')) : '')));
echo table::tds(array(array('class' => 'tableb', 'align' => 'center', 'text' => form::radio('avatar_type', 'file')), array('class' => 'tableb', 'text' => Lang::item('profile.file')), array('class' => 'tableb', 'text' => form::file('fr_avatar_file'))));
echo table::td(Lang::item('profile.profile'), 4, 'tableh2');
echo table::tds(array(array('class' => 'tableb', 'colspan' => 2, 'rowspan' => 3, 'text' => Lang::item('profile.signature')), array('class' => 'tableb', 'colspan' => 2, 'text' => forum::generate_bbcode_tags('profile', 'fr_signature'))));
echo table::tds(array(array('class' => 'tableb', 'colspan' => 2, 'align' => 'center', 'text' => form::textarea('fr_signature', $user['fr_signature']))));
echo table::tds(array(array('class' => 'tableb', 'colspan' => 2, 'text' => generate_smilies('profile', 'fr_signature'))));
echo table::tds(array(array('class' => 'tablef', 'colspan' => 4, 'text' => form::submit(Lang::item('common.change'), 'submit'))));
echo form::close();
echo table::close();
示例10: array
print table::close();
print "</div>";
print table::open();
print table::td(Lang::item('topic.topic_reply'), 2);
print form::open('forum.php?c=topic&m=reply&id=' . $topic_id, 'reply', 'post');
if (count($errors) > 0) {
print table::td(table::error($errors), 2, 'tableh2');
}
print table::tds(array(array('class' => 'tableb', 'width' => '30%', 'text' => Lang::item('topic.subject')), array('class' => 'tableb', 'width' => '70%', 'text' => form::text('subject', $form['subject']))));
if (Config::item('fr_msg_icons') == 1) {
print table::tds(array(array('class' => 'tableb', 'text' => Lang::item('topic.message_icon')), array('class' => 'tableb', 'text' => forum::generate_message_icons('icon', $icons, $form['icon']))));
}
print table::tds(array(array('class' => 'tableb', 'text' => NBSP), array('class' => 'tableb', 'text' => forum::generate_bbcode_tags('reply', 'body'))));
print table::tds(array(array('class' => 'tableb', 'text' => Lang::item('topic.message')), array('class' => 'tableb', 'text' => form::textarea('body', $form['body']))));
global $CONFIG;
if ($CONFIG['comment_captcha'] == 1 || $CONFIG['comment_captcha'] == 2 && !USER_ID) {
global $lang_common;
print table::tds(array(array('class' => 'tableb', 'text' => $lang_common['confirm']), array('class' => 'tableb', 'text' => '<input type="text" name="confirmCode" size="5" maxlength="5" class="textinput" /><img src="captcha.php" align="middle" border="0" alt="" />')));
}
print table::tds(array(array('class' => 'tableb', 'text' => NBSP), array('class' => 'tableb', 'text' => generate_smilies('reply', 'body'))));
print table::td(Lang::item('topic.addition_options'), 2, 'tablef');
print table::tds(array(array('class' => 'tableb', 'text' => Lang::item('topic.notify_this')), array('class' => 'tableb', 'text' => form::yesno('notify', $authorizer->is_notify_topic($topic_id) ? 1 : 0))));
/*
print table::tds(array(
array('class'=>'tableb', 'text'=>Lang::item('topic.upload')),
array('class'=>'tableb', 'text'=>''),
));
*/
print table::tds(array(array('class' => 'tablef', 'text' => NBSP), array('class' => 'tablef', 'text' => form::submit(Lang::item('common.reply'), 'submit') . html::jsbutton('return false;', Lang::item('common.preview'), array('id' => 'preview')) . NBSP . html::button('forum.php?c=topic&id=' . $topic_id, Lang::item('common.cancel')))));
print form::close();
print table::close();
示例11:
</span>
<?php
echo Html::button('<span class="glyphicon glyphicon-plus-sign"></span>', ["data-toggle" => "collapse", "data-target" => "#corpo-info", "style" => "float:right;", "id" => "btn-fecha_info"]);
?>
</div>
<div id="corpo-info" class="panel-body collapse">
<?php
echo DetailView::widget(['model' => $obj, 'condensed' => true, 'bordered' => true, 'hover' => true, 'enableEditMode' => false, 'mode' => DetailView::MODE_VIEW, 'attributes' => [['columns' => [['attribute' => 'groupid', 'value' => $obj->groupid], ['attribute' => 'curriculumid', 'value' => $obj->curriculum->curricularcomponent->name . '/' . $obj->curriculum->curricularcomponent->curricularcomponentversion], 'classid']], ['columns' => [['attribute' => 'curso', 'value' => $obj->curriculum->course->course->course->name . '/' . $obj->curriculum->course->course->courseversion], ['attribute' => 'learningperiodid', 'value' => $obj->learningperiod->periodid]]]]]);
?>
</div>
</div>
<p>
<?php
echo html::button('Criar Avaliação', ['value' => Url::to('index.php?r=portal-professor/evaluation/create'), 'class' => 'btn btn-success', 'id' => 'butCriaAvaliacao']);
?>
</p>
<?php
Modal::begin(['header' => '<h4>Insere Avaliação</h4>', 'id' => 'insere', 'size' => 'modal-lg', 'clientOptions' => ['backdrop' => 'static', 'keyboard' => FALSE]]);
echo "<div style='heigth:100%' id = 'modalContent'></div>";
Modal::end();
?>
<!-- Modal -->