Weather and Time Plug-in

Posted: July 22, 2012 in Uncategorized

Weather and Time Plug-in.


Features :-

1. You can display weather and time of multiple cities.

2. The front-end display is simple and flexible. So you can style the front-end easily based on your theme.

3. There are several options in plug-in admin. So you can easily manage the plug-in.

Download Plug-in

Installation and Usage :-

1. Download and install the plg-in
2. Use <?php weather_time(); ?> or <?php weather_time(array(‘city’ => ‘Your City’,’zone’ => ‘Your Time Zone’)); ?> .
3. You can use the shortcode [weather_time] or [weather_time city=”Your City” zone=”Your Time Zone”] .
4. You can also use the widget “Weather & Time” for widget area.

Screenshots :-

Comment here if you have any queries..

function replace_howdy( $wp_admin_bar ) {
    $newtitle = str_replace( 'Howdy,', 'Logged in as', $my_account->title );
    $wp_admin_bar->add_node( array(
        'id' => 'my-account',
        'title' => $newtitle,
    ) );
add_filter( 'admin_bar_menu', 'replace_howdy',25 );

To remove any item of the admin bar of your site use following code.

function wps_admin_bar() {
    global $wp_admin_bar;
add_action( 'wp_before_admin_bar_render', 'wps_admin_bar' );

use following code to show the admin bar only for the admin of your website


if (!current_user_can('manage_options')) {
	add_filter('show_admin_bar', '__return_false');

To show any warning message or notices in your wordpress admin panel/ dashboard use below code in your theme function.php file


function showMessage($message, $errormsg = false)
	if ($errormsg) {
		echo '<div id="message">';
	else {
		echo '<div id="message">';
	echo "<p><strong>$message</strong></p></div>";

function showAdminMessages()
    showMessage("Working on Theme's function.php, Do not touch it till further notice.", true);
add_action('admin_notices', 'showAdminMessages');

If you like to remove the functionality of dragging of metaboxes within the admin area and dashboard  Go to functions.php in your theme folder and add following code.

function disable_drag_metabox() {
add_action( 'admin_init', 'disable_drag_metabox' );