示例#1
0
 /**
  * Returns the version of the generator
  *
  * @since 3.0
  * @return int The version
  */
 public static function GetVersion()
 {
     return GoogleSitemapGeneratorLoader::GetVersion();
 }
 /**
  * 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;
 }
function jobman_print_other_plugins_box()
{
    $options = get_option('jobman_options');
    ?>
	<p><?php 
    _e('Job Manager provides extra functionality through the use of other plugins available for WordPress. These plugins are not required for Job Manager to function, but do provide enhancements.', 'jobman');
    ?>
</p>
	<form action="" method="post">
	<input type="hidden" name="jobmanotherpluginssubmit" value="1" />
<?php 
    wp_nonce_field('jobman-other-plugins-updatedb');
    if (class_exists('GoogleSitemapGeneratorLoader')) {
        $gxs = true;
        $gxs_status = __('Installed', 'jobman');
        $gxs_version = GoogleSitemapGeneratorLoader::GetVersion();
    } else {
        $gxs = false;
        $gxs_status = __('Not Installed', 'jobman');
    }
    ?>
		<h4><?php 
    _e('Google XML Sitemaps', 'jobman');
    ?>
</h4>
		<p><?php 
    _e('Allows you to automatically add all your job listing and job detail pages to your sitemap. By default, only the main job list is added.', 'jobman');
    ?>
</p>
		<p>
			<a href="http://wordpress.org/extend/plugins/google-sitemap-generator/"><?php 
    _e('Download', 'jobman');
    ?>
</a><br/>
			<?php 
    _e('Status', 'jobman');
    ?>
: <span class="<?php 
    echo $gxs ? 'pluginokay' : 'pluginwarning';
    ?>
"><?php 
    echo $gxs_status;
    ?>
</span><br/>
			<?php 
    echo $gxs ? __('Version', 'jobman') . ": {$gxs_version}" : '';
    ?>
			<?php 
    echo !$gxs || version_compare($gxs_version, '3.2', '<') ? ' <span class="pluginwarning">' . __('Job Manager requires Google XML Sitemaps version 3.2 or later.', 'jobman') . '</span>' : '';
    ?>
		</p>
<?php 
    if ($gxs && version_compare($gxs_version, '3.2', '>=')) {
        ?>
		<strong><?php 
        _e('Options', 'jobman');
        ?>
</strong>
		<table class="form-table">
			<tr>
				<th scope="row"><?php 
        _e('Add Job pages to your Sitemap?', 'jobman');
        ?>
</th>
				<td><input type="checkbox" value="1" name="plugin-gxs"<?php 
        echo $options['plugins']['gxs'] ? ' checked="checked"' : '';
        ?>
 /></td>
			</tr>
		</table>
<?php 
    }
    $sicaptcha = false;
    $class = 'pluginwarning';
    $sistatus = __('Not Installed', 'jobman');
    if (class_exists('siCaptcha')) {
        $sicaptcha = true;
        $class = 'pluginokay';
        $sistatus = __('Installed', 'jobman');
    }
    ?>
		<h4><?php 
    _e('SI Captcha', 'jobman');
    ?>
</h4>
		<p><?php 
    _e('Allows you to add a Captcha to your Application submission form.', 'jobman');
    ?>
</p>
		<p>
			<a href="http://wordpress.org/extend/plugins/si-captcha-for-wordpress/"><?php 
    _e('Download', 'jobman');
    ?>
</a><br/>
			<?php 
    _e('Status', 'jobman');
    ?>
: <span class="<?php 
    echo $class;
    ?>
"><?php 
    echo $sistatus;
    ?>
</span>
		</p>
<?php 
    if ($sicaptcha) {
        ?>
		<strong><?php 
        _e('Options', 'jobman');
        ?>
</strong>
		<table class="form-table">
			<tr>
				<th scope="row"><?php 
        _e('Add a captcha to the application form?', 'jobman');
        ?>
</th>
				<td><input type="checkbox" value="1" name="plugin-sicaptcha"<?php 
        echo $options['plugins']['sicaptcha'] ? ' checked="checked"' : '';
        ?>
 /></td>
			</tr>
		</table>
<?php 
    }
    ?>
		<p class="submit"><input type="submit" name="submit"  class="button-primary" value="<?php 
    _e('Update Plugin Settings', 'jobman');
    ?>
" /></p>
	</form>
<?php 
}
示例#4
0
 /**
  * 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;
 }