function _b_wp_calendar_show($option, $wp_num = "")
 {
     if (current_wp()) {
         if (!empty($_SERVER['PATH_INFO'])) {
             permlink_to_param();
         }
         init_param('GET', 'p', 'integer', '');
         init_param('GET', 'm', 'integer', '');
         init_param('GET', 'w', 'integer', '');
         init_param('GET', 'monthnum', 'integer', '');
         init_param('GET', 'year', 'integer', '');
         if (test_param('p') && !(test_param('m') || test_param('monthnum') || test_param('w'))) {
             $postHandler =& wp_handler('Post');
             $postObject =& $postHandler->get(get_param('p'));
             if ($postObject) {
                 $GLOBALS['m'] = mysql2date('Ym', $postObject->getVar('post_date'));
             }
         }
     }
     $block['wp_num'] = $wp_num;
     $block['divid'] = 'wpCalendar' . $wp_num;
     $block['style'] = block_style_get(false);
     $block['calendar'] = get_calendar(1, false);
     $_wpTpl =& new WordPresTpl('theme');
     $_wpTpl->assign('block', $block);
     $block['content'] = $_wpTpl->fetch('wp_calendar.html');
     return $block;
 }
Example #2
0
function calendar_sidebar_module($args)
{
    extract($args);
    echo $before_module . $before_title . $title . $after_title;
    get_calendar();
    echo $after_module;
}
 function b_wp_calendar_show($option, $wp_num = "")
 {
     global $wpdb, $siteurl, $wp_id, $wp_inblock, $xoopsConfig, $use_cache, $m, $monthnum, $year, $wp_mod, $wp_base;
     $id = 1;
     $use_cache = 1;
     if ($wp_num == "") {
         $wp_id = $wp_num;
         $wp_inblock = 1;
         include dirname(__FILE__) . '/../wp-config.php';
         $wp_inblock = 0;
     }
     if (current_wp()) {
         param('m', 'integer', '');
         param('monthnum', 'integer', '');
         param('year', 'integer', '');
         $m = array_key_exists('m', $_GET) ? $_GET['m'] : '';
         $monthnum = array_key_exists('monthnum', $_GET) ? $_GET['monthnum'] : '';
         $year = array_key_exists('year', $_GET) ? $_GET['year'] : '';
     }
     ob_start();
     block_style_get($wp_num);
     get_calendar(1);
     $block['content'] = ob_get_contents();
     ob_end_clean();
     return $block;
 }
function widget_quentin_calendar()
{
    ?>
<li id="calendar">
	<?php 
    get_calendar();
    ?>
</li>
<?php 
}
Example #5
0
 function widget($args, $instance)
 {
     extract($args);
     $title = apply_filters('widget_title', empty($instance['title']) ? '' : $instance['title'], $instance, $this->id_base);
     echo $before_widget;
     if ($title) {
         echo $before_title . $title . $after_title;
     }
     echo '<div id="calendar_wrap">';
     get_calendar();
     echo '</div>';
     echo $after_widget;
 }
 /**
  * @param array $args
  * @param array $instance
  */
 public function widget($args, $instance)
 {
     /** This filter is documented in wp-includes/widgets/class-wp-widget-pages.php */
     $title = apply_filters('widget_title', empty($instance['title']) ? '' : $instance['title'], $instance, $this->id_base);
     echo $args['before_widget'];
     if ($title) {
         echo $args['before_title'] . $title . $args['after_title'];
     }
     echo '<div id="calendar_wrap">';
     get_calendar();
     echo '</div>';
     echo $args['after_widget'];
 }
Example #7
0
 function widget($args, $instance)
 {
     $title = apply_filters('widget_title', empty($instance['title']) ? '&nbsp;' : $instance['title'], $instance, $this->id_base);
     echo $args['before_widget'];
     if ($title) {
         echo $args['before_title'] . $title . $args['after_title'];
     }
     echo '<div id="calendar_wrap">';
     empty($GLOBALS['polylang']->curlang) ? get_calendar() : self::get_calendar();
     #modified#
     echo '</div>';
     echo $args['after_widget'];
 }
 public function widget($args, $instance)
 {
     /** This filter is documented in wp-includes/default-widgets.php */
     $title = apply_filters('widget_title', empty($instance['title']) ? '' : $instance['title'], $instance, $this->id_base);
     echo $args['before_widget'];
     if ($title) {
         echo $args['before_title'] . $title . $args['after_title'];
     }
     echo '<div id="calendar_wrap" class="panel-body"><div class="table-responsive">';
     get_calendar();
     echo '</div></div>';
     echo $args['after_widget'];
 }
Example #9
0
 function widget($args, $instance)
 {
     extract($args);
     $title = apply_filters('widget_title', $instance['title']);
     $hide_empty = isset($instance['initial']) ? $instance['initial'] : false;
     echo $before_widget;
     if ($title) {
         echo "\n\t\t\t" . $before_title . $title . $after_title;
     }
     echo "\n\t\t\t" . '<div class="calendar-wrap">';
     get_calendar($initial);
     echo "\n\t\t\t" . '</div><!-- .calendar-wrap -->';
     echo $after_widget;
 }
 function _b_wp_calendar_show($option, $wp_num = "")
 {
     if (current_wp()) {
         init_param('GET', 'm', 'integer', '');
         init_param('GET', 'w', 'integer', '');
         init_param('GET', 'monthnum', 'integer', '');
         init_param('GET', 'year', 'integer', '');
     }
     ob_start();
     block_style_get($wp_num);
     get_calendar(1);
     $block['content'] = ob_get_contents();
     ob_end_clean();
     return $block;
 }
Example #11
0
	/**
	 * Outputs the widget based on the arguments input through the widget controls.
	 * @since 0.6
	 */
	function widget( $args, $instance ) {
		extract( $args );

		$initial = isset( $instance['initial'] ) ? $instance['initial'] : false;

		echo $before_widget;

		if ( $instance['title'] )
			echo $before_title . apply_filters( 'widget_title',  $instance['title'], $instance, $this->id_base ) . $after_title;

		echo '<div class="calendar-wrap">';
			get_calendar( $initial );
		echo '</div><!-- .calendar-wrap -->';

		echo $after_widget;
	}
Example #12
0
 function widget($args, $instance)
 {
     global $polylang;
     #added#
     extract($args);
     $title = apply_filters('widget_title', empty($instance['title']) ? '&nbsp;' : $instance['title'], $instance, $this->id_base);
     echo $before_widget;
     if ($title) {
         echo $before_title . $title . $after_title;
     }
     echo '<div id="calendar_wrap">';
     isset($polylang) && $polylang->get_languages_list() ? $this->get_calendar() : get_calendar();
     #modified#
     echo '</div>';
     echo $after_widget;
 }
 public function widget($args, $instance)
 {
     /** This filter is documented in wp-includes/default-widgets.php */
     $title = apply_filters('widget_title', empty($instance['title']) ? '' : $instance['title'], $instance, $this->id_base);
     echo $args['before_widget'];
     if ($title) {
         echo $args['before_title'] . $title . $args['after_title'];
     }
     echo '<div id="calendar_wrap">';
     if (is_null(fw_ext('translation'))) {
         get_calendar();
     } else {
         $this->get_calendar();
     }
     echo '</div>';
     echo $args['after_widget'];
 }
Example #14
0
 function widget($args, $instance)
 {
     extract($args);
     $title = apply_filters('widget_title', empty($instance['title']) ? '' : $instance['title'], $instance, $this->id_base);
     $before_widget = ' <div id="calendar-' . $args['widget_id'] . '" class="widget-container widget_calendar"> ';
     $after_widget = '</div>';
     $before_title = '<h3>';
     $after_title = '</h3>';
     echo $before_widget;
     if ($title) {
         echo $before_title . $title . $after_title;
     }
     echo '<div id="calendar_wrap">';
     get_calendar();
     echo '</div>';
     echo $after_widget;
 }
    public function widget($args, $instance)
    {
        extract($args);
        $title = isset($instance['title']) ? $instance['title'] : false;
        $class_wrap = isset($instance['class_wrap']) ? $instance['class_wrap'] : '';
        $calendar_style = isset($instance['calendar_style']) ? $instance['calendar_style'] : '';
        // Class wrap
        if ('' != $class_wrap) {
            $class_widget = $class_wrap;
        } else {
            $class_widget = uw_option('widgets_style', 'style1');
        }
        // no 'class' attribute
        if (strpos($before_widget, 'class') === false) {
            $before_widget = str_replace('>', 'class="' . $class_widget . '"', $before_widget);
        } else {
            $before_widget = str_replace('class="', 'class="' . $class_widget . ' ', $before_widget);
        }
        echo $before_widget;
        if ($title) {
            ?>
				<h3 class="uw-title">
					<span><?php 
            echo esc_attr($title);
            ?>
</span>
				</h3>
			<?php 
        }
        ?>
			<div class="uw-calendar-<?php 
        echo esc_attr($calendar_style);
        ?>
">
				<?php 
        if ('style1' == $calendar_style) {
            get_calendar(false);
        } else {
            get_calendar();
        }
        ?>
			</div>
		<?php 
        echo $after_widget;
    }
 function _b_wp_calendar_show($option, $wp_num = "")
 {
     if (current_wp()) {
         if (!empty($_SERVER['PATH_INFO'])) {
             permlink_to_param();
         }
         init_param('GET', 'm', 'integer', '');
         init_param('GET', 'w', 'integer', '');
         init_param('GET', 'monthnum', 'integer', '');
         init_param('GET', 'year', 'integer', '');
     }
     ob_start();
     block_style_get($wp_num);
     get_calendar(1);
     $block['content'] = ob_get_contents();
     ob_end_clean();
     return $block;
 }
function bfa_widget_calendar($args)
{
    extract($args);
    $options = get_option('bfa_widget_calendar');
    $title = apply_filters('widget_title', $options['title']);
    echo $before_widget;
    if (!empty($title)) {
        echo $before_title . $title . $after_title;
    }
    echo '<div id="calendar_wrap">';
    get_calendar();
    echo '</div>';
    if (!empty($title)) {
        echo $after_widget;
    } else {
        echo "</div>";
    }
}
 function b_wp_calendar_show($option, $wp_num = "")
 {
     global $wpdb, $siteurl, $wp_id, $wp_inblock, $xoopsConfig, $use_cache;
     $id = 1;
     $use_cache = 1;
     if ($wp_num == "") {
         $wp_id = $wp_num;
         $wp_inblock = 1;
         include dirname(__FILE__) . '/../wp-config.php';
         $wp_inblock = 0;
     }
     ob_start();
     block_style_get($wp_num);
     get_calendar(1);
     $block['content'] = ob_get_contents();
     ob_end_clean();
     return $block;
 }
Example #19
0
 /**
  * Outputs the widget based on the arguments input through the widget controls.
  * @since 0.6.0
  */
 function widget($args, $instance)
 {
     extract($args);
     /* Get the $initial argument. */
     $initial = !empty($instance['initial']) ? true : false;
     /* Output the theme's widget wrapper. */
     echo $before_widget;
     /* If a title was input by the user, display it. */
     if (!empty($instance['title'])) {
         echo $before_title . apply_filters('widget_title', $instance['title'], $instance, $this->id_base) . $after_title;
     }
     /* Display the calendar. */
     echo '<div class="calendar-wrap">';
     echo str_replace(array("\r", "\n", "\t"), '', get_calendar($initial, false));
     echo '</div><!-- .calendar-wrap -->';
     /* Close the theme's widget wrapper. */
     echo $after_widget;
 }
 /**
  * Outputs the widget based on the arguments input through the widget controls.
  *
  * @since  0.6.0
  * @access public
  * @param  array  $sidebar
  * @param  array  $instance
  * @return void
  */
 function widget($sidebar, $instance)
 {
     /* Set the $args. */
     $args = wp_parse_args($instance, $this->defaults);
     /* Get the $initial argument. */
     $initial = !empty($args['initial']) ? true : false;
     /* Output the sidebar's $before_widget wrapper. */
     echo $sidebar['before_widget'];
     /* If a title was input by the user, display it. */
     if (!empty($args['title'])) {
         echo $sidebar['before_title'] . apply_filters('widget_title', $args['title'], $instance, $this->id_base) . $sidebar['after_title'];
     }
     /* Display the calendar. */
     echo '<div class="calendar-wrap">';
     echo str_replace(array("\r", "\n", "\t"), '', get_calendar($initial, false));
     echo '</div><!-- .calendar-wrap -->';
     /* Close the sidebar's widget wrapper. */
     echo $sidebar['after_widget'];
 }
 function widget($args, $instance)
 {
     extract($args);
     $b = $instance['b'] = empty($instance['b']) ? '' : $instance['b'];
     $class = $b ? 'widget-boxed' : '';
     $title = apply_filters('widget_title', empty($instance['title']) ? __('', 'tfuse') : $instance['title'], $instance, $this->id_base);
     $link = apply_filters('widget_link', empty($instance['link']) ? __('', 'tfuse') : $instance['link'], $instance, $this->id_base);
     $before_title = '<h3 class="widget-title">';
     $after_title = '</h3>';
     $before_widget = ' <div class="widget widget_calendar ' . $class . '">
                             ';
     $after_widget = '</div>';
     $title = tfuse_qtranslate($title);
     echo $before_widget;
     if ($title) {
         echo $before_title . $title . $after_title;
     }
     echo '<div id="calendar_wrap">';
     get_calendar(false);
     echo '</div>';
     echo $after_widget;
 }
 function b_wp_calendar_show($option, $wp_num = "")
 {
     $id = 1;
     $GLOBALS['use_cache'] = 1;
     if ($wp_num == "") {
         $GLOBALS['wp_id'] = $wp_num;
         $GLOBALS['wp_inblock'] = 1;
         require dirname(__FILE__) . '/../wp-config.php';
         $GLOBALS['wp_inblock'] = 0;
     }
     if (current_wp()) {
         init_param('GET', 'm', 'integer', '');
         init_param('GET', 'w', 'integer', '');
         init_param('GET', 'monthnum', 'integer', '');
         init_param('GET', 'year', 'integer', '');
     }
     ob_start();
     block_style_get($wp_num);
     get_calendar(1);
     $block['content'] = ob_get_contents();
     ob_end_clean();
     return $block;
 }
 function _b_wp_calendar_show($option, $wp_num = "")
 {
     if (current_wp()) {
         if (!empty($_SERVER['PATH_INFO'])) {
             permlink_to_param();
         }
         init_param('GET', 'p', 'integer', '');
         init_param('GET', 'm', 'integer', '');
         init_param('GET', 'w', 'integer', '');
         init_param('GET', 'monthnum', 'integer', '');
         init_param('GET', 'year', 'integer', '');
         if (test_param('p') && !(test_param('m') || test_param('monthnum') || test_param('w'))) {
             $postHandler =& wp_handler('Post');
             $postObject =& $postHandler->get(get_param('p'));
             $GLOBALS['m'] = mysql2date('Ym', $postObject->getVar('post_date'));
         }
     }
     ob_start();
     block_style_get();
     get_calendar(1);
     $block['content'] = ob_get_contents();
     ob_end_clean();
     return $block;
 }
Example #24
0
</ul>
	</div>

	<div class="sub-obar">
<ul>
<?php 
if (!function_exists('dynamic_sidebar') || !dynamic_sidebar(3)) {
    ?>
	<li><h2><?php 
    _e('Calendar');
    ?>
</h2>
	<ul>
		<li><?php 
    get_calendar();
    ?>
</li>
	</ul>
	</li>
	<li><h2><?php 
    _e('Search');
    ?>
</h2>
	<ul>
		<li><?php 
    include TEMPLATEPATH . '/searchform.php';
    ?>
</li>
	</ul>
	</li>
 function widget($args, $instance)
 {
     extract($args);
     /** This filter is documented in wp-includes/default-widgets.php */
     $title = apply_filters('widget_title', empty($instance['title']) ? '' : $instance['title'], $instance, $this->id_base);
     echo $before_widget;
     if ($title) {
         echo $before_title . $title . $after_title;
     }
     echo '<div id="calendar_wrap">';
     get_calendar();
     echo '</div>';
     echo $after_widget;
 }
Example #26
0
	   <li><h2><?php 
    _e('Author', 'kubrick');
    ?>
</h2>
	     <p>A little something about you, the author. Nothing lengthy, just an overview.</p>
	   </li>
	   -->
      <div class="sidebar_profile sidebar_text">
	<h2 class="hidden">About</h2>
	<p>ライター/エディター/プログラマー/Webディレクター、hylomのブログです。ご興味のある方は<a href="http://twitter.com/hylom">つぶやき</a>や<a href="http://sourceforge.jp/magazine/search?tid=209">執筆記事</a>などもどうぞ。</p>
      </div>

      <h2 class="hidden">カレンダー</h2>
      <div class="sidebar_calendar sidebar_text">
	<?php 
    get_calendar(false);
    ?>
      </div>

      <div class="sidebar_resent sidebar_text">
	<h2>最近の記事</h2>
	<ul>
	  <?php 
    wp_get_archives('type=postbypost&limit=10');
    ?>
	</ul>
      </div>
      
      <div class="sidebar_archives sidebar_text">
	<h2>過去の記事(過去12か月分)</h2>
	<ul>
function b_wp_calendar_show($option)
{
    $id = 1;
    global $dateformat, $time_difference, $siteurl, $blogfilename;
    global $tablelinks, $tablelinkcategories;
    global $querystring_start, $querystring_equal, $querystring_separator, $month, $wpdb, $start_of_week;
    global $tableposts, $tablepost2cat, $tablecomments, $tablecategories;
    require_once dirname(__FILE__) . '/../wp-blog-header.php';
    ob_flush();
    ob_start();
    echo <<<EOD
\t<style type="text/css" media="screen">
\t\t#wp-calendar {
\t\t\tempty-cells: show;
\t\t\tfont-size: 14px;
\t\t\tmargin: 0;
\t\t\twidth: 90%;
\t\t}
\t\t#wp-calendar #next a {
\t\t\tpadding-right: 10px;
\t\t\ttext-align: right;
\t\t}

\t\t#wp-calendar #prev a {
\t\t\tpadding-left: 10px;
\t\t\ttext-align: left;
\t\t}

\t\t#wp-calendar a {
\t\t\tdisplay: block;
\t\t\tcolor: #000000;
\t\t\ttext-decoration: none;
\t\t}

\t\t#wp-calendar a:hover {
\t\t\tbackground: #A6C9E6;
\t\t\tcolor: #333;
\t\t}

\t\t#wp-calendar caption {
\t\t\tfont-weight: bold;
\t\t\tfont-size: 110%;
\t\t\tcolor: #632;
\t\t\ttext-align: left;
\t\t}

\t\t#wp-calendar td {
\t\t\tcolor: #aaa;
\t\t\tfont: normal 12px "ƒqƒ‰ƒMƒmŠpƒS Pro W3", Osaka, Verdana, "‚l‚r ‚oƒSƒVƒbƒN", sans-serif;
\t\t\tletter-spacing: normal;
\t\t\tpadding: 2px 0;
\t\t\ttext-align: center;
\t\t}

\t\t#wp-calendar td.pad:hover {
\t\t\tbackground: #fff;
\t\t}

\t\t#wp-calendar #today {
\t\t\tbackground: #D85F7D;
\t\t\tcolor: #ffffff;
\t\t}

\t\t#wp-calendar th {
\t\t\tfont-style: normal;
\t\t\tfont-size: 11px;
\t\t\ttext-transform: capitalize;
\t\t}
\t</style>
EOD;
    get_calendar(2);
    $block['content'] = ob_get_contents();
    ob_end_clean();
    return $block;
}
Example #28
0
    function widget($args, $instance)
    {
        global $post, $wp_query;
        Protect();
        extract($args, EXTR_SKIP);
        echo $before_widget;
        if (!empty($instance)) {
            extract($instance);
        }
        ?>
			<?php 
        if (comicpress_themeinfo('enable_caps')) {
            ?>
<div id="wp-calendar-head"></div><?php 
        }
        ?>
			<div id="wp-calendar-wrap">
				<?php 
        if (!empty($thumbnail)) {
            ?>
					<div class="wp-calendar-download">
					<?php 
            if (!empty($link)) {
                ?>
						<a href="<?php 
                echo esc_attr($link);
                ?>
"><img src="<?php 
                echo esc_attr($thumbnail);
                ?>
" class="wp-calendar-thumb" alt="" /></a>
					<?php 
            } else {
                ?>
						<img src="<?php 
                echo esc_attr($thumbnail);
                ?>
" class="wp-calendar-thumb" alt="" />
					<?php 
            }
            ?>
						<div class="wp-calendar-download-links">
							<?php 
            if (!empty($small) || !empty($medium) || !empty($large)) {
                ?>
								<?php 
                _e('DOWNLOAD', 'comicpress');
                ?>
								<?php 
                foreach (array('small' => array(__('Download Small', 'comicpress'), __('S', 'comicpress')), 'medium' => array(__('Download Medium', 'comicpress'), __('M', 'comicpress')), 'large' => array(__('Download Large', 'comicpress'), __('L', 'comicpress'))) as $field => $text) {
                    if (!empty(${$field})) {
                        ?>
<a href="<?php 
                        echo esc_attr(${$field});
                        ?>
" title="<?php 
                        echo esc_attr($text[0]);
                        ?>
"><?php 
                        echo esc_html($text[1]);
                        ?>
</a><?php 
                    }
                }
            }
            ?>
						</div>
					</div>
				<?php 
        }
        ?>
			<?php 
        get_calendar();
        ?>
			</div>
			<?php 
        if (comicpress_themeinfo('enable_caps')) {
            ?>
<div id="wp-calendar-foot"></div><?php 
        }
        ?>
		<?php 
        echo $after_widget;
        UnProtect();
    }
Example #29
0
    });
});
$app->group('/calendars', function () use($app) {
    global $check_token_exists;
    global $decode_body;
    $app->get('', $check_token_exists, function () {
        get_calendars();
    });
    $app->post('', $check_token_exists, $decode_body, function () {
        create_calendar();
    });
    $app->group('/:calendar_id', function () use($app) {
        global $check_token_exists;
        global $decode_body;
        $app->get('', $check_token_exists, function ($calendar_id) {
            get_calendar($calendar_id);
        });
        $app->put('', $check_token_exists, $decode_body, function ($calendar_id) {
            edit_calendar($calendar_id);
        });
        $app->delete('', $check_token_exists, function ($calendar_id) {
            delete_calendar($calendar_id);
        });
        $app->group('/members', function () use($app) {
            global $check_token_exists;
            global $decode_body;
            $app->get('', $check_token_exists, function ($calendar_id) {
                get_members($calendar_id);
            });
            $app->post('', $check_token_exists, $decode_body, function ($calendar_id) {
                add_member($calendar_id);
    public static function show_custom_sidebars()
    {
        //set areas
        $sidebars = TMM::get_option('sidebars');
        //get current page id
        $type = "page";
        $current_id = 0;
        wp_reset_query();
        global $post;
        if (is_category()) {
            $type = 'cat';
            $current_id = get_query_var('cat');
        } else {
            if (is_page()) {
                $type = 'page';
                $current_id = $post->ID;
            }
        }
        //open wigitised areas
        $show_default_sidebar = true;
        if (is_array($sidebars)) {
            //show custom sidebar
            foreach ($sidebars as $area) {
                if ($type == "cat") {
                    $cat_id = $current_id;
                    if (in_array($cat_id, $area['cat'])) {
                        if ($cat_id != 0) {
                            $show_default_sidebar = false;
                            dynamic_sidebar($area['name']);
                        }
                    }
                } else {
                    $post_id = $current_id;
                    if (in_array($post_id, $area['page'])) {
                        if ($post_id != 0) {
                            $show_default_sidebar = false;
                            dynamic_sidebar($area['name']);
                        }
                    }
                }
            }
        }
        //show default sidebar
        if ($show_default_sidebar) {
            if (function_exists('dynamic_sidebar') and dynamic_sidebar('Thememakers Default Sidebar')) {
            } else {
                ?>
				<div class="widget widget_categories">
					<h3 class="widget-title"><?php 
                _e('Categories', 'almera');
                ?>
</h3>
					<ul class="categories">
						<?php 
                wp_list_categories('sort_column=name&optioncount=1&hierarchical=0&title_li=0');
                ?>
					</ul>                    
				</div>
				<div class="widget widget_calendar">
					<h3 class="widget-title"><?php 
                _e('Calendar', 'almera');
                ?>
</h3>
					<?php 
                get_calendar();
                ?>
				</div>

				<div class="widget widget_meta">
					<h3 class="widget-title"><?php 
                _e('Meta', 'almera');
                ?>
</h3>
					<ul>
						<?php 
                wp_register();
                ?>
						<li>
							<?php 
                wp_loginout();
                ?>
						</li>
						<?php 
                wp_meta();
                ?>
					</ul>

				</div>				

			<?php 
            }
        }
    }