本文整理汇总了PHP中GoogleSitemapGeneratorLoader::GetBaseName方法的典型用法代码示例。如果您正苦于以下问题:PHP GoogleSitemapGeneratorLoader::GetBaseName方法的具体用法?PHP GoogleSitemapGeneratorLoader::GetBaseName怎么用?PHP GoogleSitemapGeneratorLoader::GetBaseName使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类GoogleSitemapGeneratorLoader
的用法示例。
在下文中一共展示了GoogleSitemapGeneratorLoader::GetBaseName方法的8个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: GetBackLink
/**
* Returns a link pointing back to the plugin page in WordPress
*
* @since 3.0
* @return string The full url
*/
public static function GetBackLink()
{
global $wp_version;
$url = admin_url("options-general.php?page=" . GoogleSitemapGeneratorLoader::GetBaseName());
return $url;
}
示例2: HtmlShowOptionsPage
//.........这里部分代码省略.........
<!--[if lt IE 7]>
<style type="text/css">
div#advancedstuff {
width:735px;
}
</style>
<![endif]-->
<?php
} else {
?>
<style type="text/css">
div.updated-message {
margin-left:0; margin-right:0;
}
</style>
<?php
}
?>
<div class="wrap" id="sm_div">
<form method="post" action="<?php
echo $this->sg->GetBackLink();
?>
">
<h2><?php
_e('XML Sitemap Generator for WordPress', 'sitemap');
echo " " . $this->sg->GetVersion();
?>
</h2>
<?php
if (function_exists("wp_update_plugins") && (!defined('SM_NO_UPDATE') || SM_NO_UPDATE == false)) {
wp_update_plugins();
$file = GoogleSitemapGeneratorLoader::GetBaseName();
$plugin_data = get_plugin_data(GoogleSitemapGeneratorLoader::GetPluginFile());
$current = get_option('update_plugins');
if (isset($current->response[$file])) {
$r = $current->response[$file];
?>
<div id="update-nag" class="sm-update-nag"><?php
if (!current_user_can('edit_plugins') || version_compare($wp_version, "2.5", "<")) {
printf(__('There is a new version of %1$s available. <a href="%2$s">Download version %3$s here</a>.', 'default'), $plugin_data['Name'], $r->url, $r->new_version);
} else {
if (empty($r->package)) {
printf(__('There is a new version of %1$s available. <a href="%2$s">Download version %3$s here</a> <em>automatic upgrade unavailable for this plugin</em>.', 'default'), $plugin_data['Name'], $r->url, $r->new_version);
} else {
printf(__('There is a new version of %1$s available. <a href="%2$s">Download version %3$s here</a> or <a href="%4$s">upgrade automatically</a>.', 'default'), $plugin_data['Name'], $r->url, $r->new_version, wp_nonce_url("update.php?action=upgrade-plugin&plugin={$file}", 'upgrade-plugin_' . $file));
}
}
?>
</div><?php
}
}
?>
<?php
if (version_compare($wp_version, "2.5", "<")) {
?>
<script type="text/javascript" src="../wp-includes/js/dbx.js"></script>
<script type="text/javascript">
//<![CDATA[
addLoadEvent( function() {
var manager = new dbxManager('sm_sitemap_meta_33');
//create new docking boxes group
var meta = new dbxGroup(
示例3: CallHtmlShowHelpList
function CallHtmlShowHelpList($filterVal, $screen)
{
$id = get_plugin_page_hookname(GoogleSitemapGeneratorLoader::GetBaseName(), 'options-general.php');
if ($screen == $id) {
$links = array(__('Plugin Homepage', 'sitemap') => 'http://www.arnebrachhold.de/redir/sitemap-help-home/', __('My Sitemaps FAQ', 'sitemap') => 'http://www.arnebrachhold.de/redir/sitemap-help-faq/');
$filterVal[$id] = '';
$i = 0;
foreach ($links as $text => $url) {
$filterVal[$id] .= '<a href="' . $url . '">' . $text . '</a>' . ($i < count($links) - 1 ? '<br />' : '');
$i++;
}
}
return $filterVal;
}
示例4: RegisterPluginLinks
function RegisterPluginLinks($links, $file)
{
$base = GoogleSitemapGeneratorLoader::GetBaseName();
if ($file == $base) {
$links[] = '<a href="options-general.php?page=sitemap.php">' . __('Settings') . '</a>';
$links[] = '<a href="http://www.arnebrachhold.de/redir/sitemap-plist-faq/">' . __('FAQ') . '</a>';
$links[] = '<a href="http://www.arnebrachhold.de/redir/sitemap-plist-support/">' . __('Support') . '</a>';
$links[] = '<a href="http://www.arnebrachhold.de/redir/sitemap-plist-donate/">' . __('Donate') . '</a>';
}
return $links;
}
示例5: HtmlShowOptionsPage
//.........这里部分代码省略.........
</style>
<style type="text/css">
.sm-padded .inside {
margin:12px!important;
}
.sm-padded .inside ul {
margin:6px 0 12px 0;
}
.sm-padded .inside input {
padding:1px;
margin:0;
}
</style>
<div class="wrap" id="sm_div">
<form method="post" action="<?php
echo $this->sg->GetBackLink();
?>
">
<h2><?php
_e('XML Sitemap Generator for WordPress', 'sitemap');
echo " " . $this->sg->GetVersion();
?>
</h2>
<?php
if (function_exists("wp_update_plugins") && (!defined('SM_NO_UPDATE') || SM_NO_UPDATE == false)) {
wp_update_plugins();
$file = GoogleSitemapGeneratorLoader::GetBaseName();
$plugin_data = get_plugin_data(GoogleSitemapGeneratorLoader::GetPluginFile());
$current = function_exists('get_transient') ? get_transient('update_plugins') : get_option('update_plugins');
if (isset($current->response[$file])) {
$r = $current->response[$file];
?>
<div id="update-nag" class="sm-update-nag"><?php
if (!current_user_can('edit_plugins')) {
printf(__('There is a new version of %1$s available. <a href="%2$s">Download version %3$s here</a>.', 'default'), $plugin_data['Name'], $r->url, $r->new_version);
} else {
if (empty($r->package)) {
printf(__('There is a new version of %1$s available. <a href="%2$s">Download version %3$s here</a> <em>automatic upgrade unavailable for this plugin</em>.', 'default'), $plugin_data['Name'], $r->url, $r->new_version);
} else {
printf(__('There is a new version of %1$s available. <a href="%2$s">Download version %3$s here</a> or <a href="%4$s">upgrade automatically</a>.', 'default'), $plugin_data['Name'], $r->url, $r->new_version, wp_nonce_url("update.php?action=upgrade-plugin&plugin={$file}", 'upgrade-plugin_' . $file));
}
}
?>
</div><?php
}
}
if (get_option('blog_public') != 1) {
?>
<div class="error"><p><?php
echo str_replace("%s", "options-privacy.php", __('Your blog is currently blocking search engines! Visit the <a href="%s">privacy settings</a> to change this.', 'sitemap'));
?>
</p></div><?php
}
?>
<?php
if (!$snl) {
?>
<div id="poststuff" class="metabox-holder has-right-sidebar">
示例6: GetBackLink
/**
* Returns a link pointing back to the plugin page in WordPress
*
* @since 3.0
* @return string The full url
*/
public static function GetBackLink()
{
global $wp_version;
$url = admin_url("options-general.php?page=" . GoogleSitemapGeneratorLoader::GetBaseName());
//Some browser cache the page... great! So lets add some no caching params depending on the WP and plugin version
$url .= '&sm_wpv=' . $wp_version . '&sm_pv=' . GoogleSitemapGeneratorLoader::GetVersion();
return $url;
}
示例7: GetBackLink
/**
* Returns a link pointing back to the plugin page in NXTClass
*
* @since 3.0
* @return string The full url
*/
function GetBackLink()
{
global $nxt_version;
$url = '';
//admin_url was added in nxt 2.6.0
if (function_exists("admin_url")) {
$url = admin_url("options-general.php?page=" . GoogleSitemapGeneratorLoader::GetBaseName());
} else {
$url = $_SERVER['PHP_SELF'] . "?page=" . GoogleSitemapGeneratorLoader::GetBaseName();
}
//Some browser cache the page... great! So lets add some no caching params depending on the nxt and plugin version
$url .= '&sm_nxtv=' . $nxt_version . '&sm_pv=' . GoogleSitemapGeneratorLoader::GetVersion();
return $url;
}
示例8: GetBackLink
/**
* Returns a link pointing back to the plugin page in WordPress
*
* @since 3.0
* @return string The full url
*/
function GetBackLink()
{
//admin_url was added in WP 2.6.0
if (function_exists("admin_url")) {
return admin_url("options-general.php?page=" . GoogleSitemapGeneratorLoader::GetBaseName());
} else {
return $_SERVER['PHP_SELF'] . "?page=" . GoogleSitemapGeneratorLoader::GetBaseName();
}
}