本文整理汇总了PHP中vibe_site_url函数的典型用法代码示例。如果您正苦于以下问题:PHP vibe_site_url函数的具体用法?PHP vibe_site_url怎么用?PHP vibe_site_url使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了vibe_site_url函数的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: vibe_site_url
<input type="submit" id="searchsubmit" value="Search" />
</div>
</form>
</div>
<div class="row">
<div class="col-md-9 col-sm-6 col-xs-4">
<?php
if (is_home()) {
echo '<h1 id="logo">';
} else {
echo '<h2 id="logo">';
}
?>
<a href="<?php
echo vibe_site_url();
?>
"><img src="<?php
echo apply_filters('wplms_logo_url', VIBE_URL . '/assets/images/logo.png', 'header');
?>
" alt="<?php
echo get_bloginfo('name');
?>
" /></a>
<?php
if (is_home()) {
echo '</h1>';
} else {
echo '</h2>';
}
$args = apply_filters('wplms-main-menu', array('theme_location' => 'main-menu', 'container' => 'nav', 'menu_class' => 'menu', 'walker' => new vibe_walker(), 'fallback_cb' => 'vibe_set_menu'));
示例2: do_action
do_action('bp_sidebar_me');
?>
</div>
<?php
do_action('bp_after_sidebar_me');
/***** If the user is not logged in, show the log form and account creation link *****/
} else {
if (!isset($user_login)) {
$user_login = '';
}
do_action('bp_before_sidebar_login_form');
?>
<form name="login-form" id="vbp-login-form" class="standard-form" action="<?php
echo apply_filters('wplms_login_widget_action', vibe_site_url('wp-login.php', 'login-post'));
?>
" method="post">
<div class="row">
<div class="col-md-6 col-sm-6">
<label><?php
_e('Username', 'vibe');
?>
<br />
<input type="text" name="log" id="side-user-login" class="input" tabindex="1" value="<?php
echo esc_attr(stripslashes($user_login));
?>
" /></label>
示例3: widget
function widget($args, $instance)
{
extract($args);
echo $before_widget;
if (is_user_logged_in()) {
do_action('bp_before_sidebar_me');
?>
<div id="sidebar-me">
<div id="bpavatar">
<?php
bp_loggedin_user_avatar('type=full');
?>
</div>
<ul>
<li id="username"><a
href="<?php
bp_loggedin_user_link();
?>
"><?php
bp_loggedin_user_fullname();
?>
</a></li>
<li><a href="<?php
echo bp_loggedin_user_domain() . BP_XPROFILE_SLUG;
?>
/"
title="<?php
_e('View profile', 'vibe');
?>
"><?php
_e('View profile', 'vibe');
?>
</a>
</li>
<li id="vbplogout"><a href="<?php
echo wp_logout_url(get_permalink());
?>
"
id="destroy-sessions" rel="nofollow" class="logout"
title="<?php
_e('Log Out', 'vibe');
?>
"><i
class="icon-close-off-2"></i> <?php
_e('LOGOUT', 'vibe');
?>
</a></li>
<li id="admin_panel_icon"><?php
if (current_user_can("edit_posts")) {
echo '<a href="' . vibe_site_url() . 'wp-admin/" title="' . __('Access admin panel', 'vibe') . '"><i class="icon-settings-1"></i></a>';
}
?>
</li>
</ul>
<ul>
<?php
$loggedin_menu = array('courses' => array('icon' => 'icon-book-open-1', 'label' => __('Courses', 'vibe'), 'link' => bp_loggedin_user_domain() . BP_COURSE_SLUG), 'stats' => array('icon' => 'icon-analytics-chart-graph', 'label' => __('Stats', 'vibe'), 'link' => bp_loggedin_user_domain() . BP_COURSE_SLUG . '/' . BP_COURSE_STATS_SLUG));
if (bp_is_active('messages')) {
$loggedin_menu['messages'] = array('icon' => 'icon-letter-mail-1', 'label' => __('Inbox', 'vibe') . (messages_get_unread_count() ? ' <span>' . messages_get_unread_count() . '</span>' : ''), 'link' => bp_loggedin_user_domain() . BP_MESSAGES_SLUG);
$n = vbp_current_user_notification_count();
$loggedin_menu['notifications'] = array('icon' => 'icon-exclamation', 'label' => __('Notifications', 'vibe') . ($n ? ' <span>' . $n . '</span>' : ''), 'link' => bp_loggedin_user_domain() . BP_NOTIFICATIONS_SLUG);
}
if (bp_is_active('groups')) {
$loggedin_menu['groups'] = array('icon' => 'icon-myspace-alt', 'label' => __('Groups', 'vibe'), 'link' => bp_loggedin_user_domain() . BP_GROUPS_SLUG);
}
$loggedin_menu['settings'] = array('icon' => 'icon-settings', 'label' => __('Settings', 'vibe'), 'link' => bp_loggedin_user_domain() . BP_SETTINGS_SLUG);
$loggedin_menu = apply_filters('wplms_logged_in_top_menu', $loggedin_menu);
foreach ($loggedin_menu as $item) {
echo '<li><a href="' . $item['link'] . '"><i class="' . $item['icon'] . '"></i>' . $item['label'] . '</a></li>';
}
?>
</ul>
<?php
do_action('bp_sidebar_me');
?>
</div>
<?php
do_action('bp_after_sidebar_me');
/***** If the user is not logged in, show the log form and account creation link *****/
} else {
if (!isset($user_login)) {
$user_login = '';
}
do_action('bp_before_sidebar_login_form');
?>
<form name="login-form" id="vbp-login-form" class="standard-form"
action="<?php
echo apply_filters('wplms_login_widget_action', vibe_site_url('wp-login.php', 'login-post'));
?>
" method="post">
<label><?php
_e('Username', 'vibe');
?>
<br/>
<input type="text" name="log" id="side-user-login" class="input" tabindex="1"
value="<?php
echo esc_attr(stripslashes($user_login));
//.........这里部分代码省略.........
示例4: wplms_start_course_go_home
function wplms_start_course_go_home()
{
if (!is_user_logged_in()) {
wp_redirect(vibe_site_url());
exit;
}
}
示例5: widget
function widget($args, $instance)
{
extract($args);
echo $before_widget;
if (is_user_logged_in()) {
do_action('bp_before_sidebar_me');
?>
<div id="sidebar-me">
<div id="bpavatar">
<a href="<?php
echo bp_loggedin_user_domain() . BP_XPROFILE_SLUG;
?>
/" title="<?php
_e('Thông tin cá nhân', 'vibe');
?>
"><?php
bp_loggedin_user_avatar('type=full');
?>
</a>
</div>
<ul style="width: 145px">
<li id="username"><a href="<?php
bp_loggedin_user_link();
?>
"><?php
bp_loggedin_user_fullname();
?>
</a></li>
<li><a href="<?php
echo bp_loggedin_user_domain() . BP_XPROFILE_SLUG;
?>
/" title="<?php
_e('Thông tin cá nhân', 'vibe');
?>
"><?php
_e('Thông tin cá nhân', 'vibe');
?>
</a></li>
<li id="vbplogout"><a href="<?php
echo wp_logout_url(get_permalink());
?>
" id="destroy-sessions" rel="nofollow" class="logout" title="<?php
_e('Đăng xuất', 'vibe');
?>
"><?php
_e('Đăng xuất', 'vibe');
?>
</a></li>
<li id="admin_panel_icon"><?php
if (current_user_can("edit_posts")) {
echo '<a href="' . vibe_site_url() . 'wp-admin/" title="' . __('Access admin panel', 'vibe') . '"><i class="icon-settings-1"></i></a>';
}
?>
</li>
</ul>
<ul>
<?php
function child_wplms_get_mycred_link()
{
$mycred = get_option('mycred_pref_core');
if (isset($mycred['buddypress']) && isset($mycred['buddypress']['history_url']) && isset($mycred['buddypress']['history_location']) && $mycred['buddypress']['history_location']) {
$link = bp_get_loggedin_user_link() . $mycred['buddypress']['history_url'];
} else {
$link = '#';
}
return $link;
}
$loggedin_menu = array('taikhoan' => array('icon' => 'icon-book-open-1', 'label' => __('Tài khoản: ' . apply_filters('get_point_user', ''), 'vibe'), 'link' => child_wplms_get_mycred_link()), 'naptientaokhoan' => array('icon' => 'icon-book-open-1', 'label' => __('Nạp tiền tài khoản', 'vibe'), 'link' => get_home_url() . '/thanh-toan-khoa-hoc/'), 'courses' => array('icon' => 'icon-book-open-1', 'label' => __('Khóa học của tôi', 'vibe'), 'link' => bp_loggedin_user_domain() . BP_COURSE_SLUG));
if (bp_is_active('messages')) {
$loggedin_menu['messages'] = array('icon' => 'icon-letter-mail-1', 'label' => __('Hộp thư đến', 'vibe') . (messages_get_unread_count() ? ' <span>' . messages_get_unread_count() . '</span>' : ''), 'link' => bp_loggedin_user_domain() . BP_MESSAGES_SLUG);
$n = vbp_current_user_notification_count();
// $loggedin_menu['notifications']=array(
// 'icon' => 'icon-exclamation',
// 'label' => __('Thông báo','vibe').(($n)?' <span>'.$n.'</span>':''),
// 'link' => bp_loggedin_user_domain().BP_NOTIFICATIONS_SLUG
// );
}
if (bp_is_active('groups')) {
$loggedin_menu['groups'] = array('icon' => 'icon-myspace-alt', 'label' => __('Nhóm', 'vibe'), 'link' => bp_loggedin_user_domain() . BP_GROUPS_SLUG);
}
$loggedin_menu = apply_filters('wplms_logged_in_top_menu', $loggedin_menu);
foreach ($loggedin_menu as $item) {
echo '<li><a href="' . $item['link'] . '"><i class="' . $item['icon'] . '"></i>' . $item['label'] . '</a></li>';
}
?>
</ul>
<?php
do_action('bp_sidebar_me');
?>
</div>
<?php
do_action('bp_after_sidebar_me');
/***** If the user is not logged in, show the log form and account creation link *****/
} else {
if (!isset($user_login)) {
$user_login = '';
}
do_action('bp_before_sidebar_login_form');
?>
//.........这里部分代码省略.........
示例6: _e
_e('View profile', 'vibe');
?>
</a></li>
<li id="vbplogout"><a href="<?php
echo wp_logout_url(get_permalink());
?>
" id="destroy-sessions" rel="nofollow" class="logout" title="<?php
_e('Log Out', 'vibe');
?>
"><i class="icon-close-off-2"></i> <?php
_e('LOGOUT', 'vibe');
?>
</a></li>
<li id="admin_panel_icon"><?php
if (current_user_can("edit_posts")) {
echo '<a href="' . vibe_site_url() . 'wp-admin/" title="' . __('Access admin panel', 'vibe') . '"><i class="icon-settings-1"></i></a>';
}
?>
</li>
</ul>
<ul>
<?php
$loggedin_menu = array('courses' => array('icon' => 'icon-book-open-1', 'label' => __('Courses', 'vibe'), 'link' => bp_loggedin_user_domain() . BP_COURSE_SLUG), 'stats' => array('icon' => 'icon-analytics-chart-graph', 'label' => __('Stats', 'vibe'), 'link' => bp_loggedin_user_domain() . BP_COURSE_SLUG . '/' . BP_COURSE_STATS_SLUG));
if (bp_is_active('messages')) {
$loggedin_menu['messages'] = array('icon' => 'icon-letter-mail-1', 'label' => __('Inbox', 'vibe') . (messages_get_unread_count() ? ' <span>' . messages_get_unread_count() . '</span>' : ''), 'link' => bp_loggedin_user_domain() . BP_MESSAGES_SLUG);
$n = vbp_current_user_notification_count();
$loggedin_menu['notifications'] = array('icon' => 'icon-exclamation', 'label' => __('Notifications', 'vibe') . ($n ? ' <span>' . $n . '</span>' : ''), 'link' => bp_loggedin_user_domain() . BP_NOTIFICATIONS_SLUG);
}
if (bp_is_active('groups')) {
$loggedin_menu['groups'] = array('icon' => 'icon-myspace-alt', 'label' => __('Groups', 'vibe'), 'link' => bp_loggedin_user_domain() . BP_GROUPS_SLUG);
}