Exemplo n.º 1
0
function widget_recent_posts_multi_control($args)
{
    global $st_Options, $st_Settings;
    $st_ = array();
    // Post type names
    $st_['st_post'] = !empty($st_Settings['ctp_post']) ? $st_Settings['ctp_post'] : $st_Options['ctp']['post'];
    $prefix = 'recent-posts-multi';
    $options = get_option('widget_recent_posts_multi');
    if (empty($options)) {
        $options = array();
    }
    if (isset($options[0])) {
        unset($options[0]);
    }
    // update options array
    if (!empty($_POST[$prefix]) && is_array($_POST)) {
        foreach ($_POST[$prefix] as $widget_number => $values) {
            if (empty($values) && isset($options[$widget_number])) {
                // user clicked cancel
                continue;
            }
            if (!isset($options[$widget_number]) && $args['number'] == -1) {
                $args['number'] = $widget_number;
                $options['last_number'] = $widget_number;
            }
            $options[$widget_number] = $values;
        }
        // update number
        if ($args['number'] == -1 && !empty($options['last_number'])) {
            $args['number'] = $options['last_number'];
        }
        // clear unused options and update options in DB. return actual options array
        $options = st_smart_multiwidget_update($prefix, $options, $_POST[$prefix], $_POST['sidebar'], 'widget_recent_posts_multi');
    }
    $number = $args['number'] == -1 ? '%i%' : $args['number'];
    // Vars
    $opts = @$options[$number];
    $title = @$opts['title'];
    $post_type = @$opts['post_type'];
    $type = @$opts['type'];
    $timeframe = @$opts['timeframe'];
    $cats = @$opts['cats'];
    $qty = @$opts['qty'];
    $thumb = @$opts['thumb'];
    $date = @$opts['date'];
    $excerpt = @$opts['excerpt'];
    $cache = @$opts['cache'];
    ?>

			<fieldset class="panel-fieldset metabox-fieldset">
				<legend><?php 
    _e('Title', 'stkit');
    ?>
</legend>
	
				<input type="text" name="<?php 
    echo $prefix . '[' . $number;
    ?>
][title]" value="<?php 
    echo $title;
    ?>
" />
				<small><?php 
    _e('Widget title.', 'stkit');
    ?>
</small>
	
				<div class="clear"><!-- --></div>
			</fieldset>
		
			<fieldset class="panel-fieldset metabox-fieldset"><legend><?php 
    _e('Posts', 'stkit');
    ?>
</legend>

				<?php 
    if (!empty($st_Settings['projects_status']) && $st_Settings['projects_status'] == 'yes') {
        ?>

						<label><input type="radio" value="post" name="<?php 
        echo $prefix . '[' . $number;
        ?>
][post_type]"
							<?php 
        if (!$post_type || $post_type == 'post') {
            echo 'checked="checked"';
        }
        ?>
 /> <?php 
        _e('Posts', 'stkit');
        ?>
</label>
		
						<label><input type="radio" value="<?php 
        echo $st_['st_post'];
        ?>
" name="<?php 
        echo $prefix . '[' . $number;
        ?>
][post_type]"
							<?php 
        if ($post_type == $st_['st_post']) {
            echo 'checked="checked"';
        }
        ?>
 /> <?php 
        _e('Projects', 'stkit');
        ?>
</label>
		
						<p><small><?php 
        _e('Select a type of posts.', 'stkit');
        ?>
</small></p>
		
		
						<div class="clear"><!-- --></div><?php 
    }
    ?>


				<select name="<?php 
    echo $prefix . '[' . $number;
    ?>
][type]">
					<option value="recent" <?php 
    if ($type == 'recent') {
        echo 'selected';
    }
    ?>
><?php 
    _e('Recent', 'stkit');
    ?>
</option>
					<option value="random" <?php 
    if ($type == 'random') {
        echo 'selected';
    }
    ?>
><?php 
    _e('Random', 'stkit');
    ?>
</option>
					<option value="most_viewed" <?php 
    if ($type == 'most_viewed') {
        echo 'selected';
    }
    if (empty($st_Settings['post_views']) || $st_Settings['post_views'] != 'yes') {
        echo 'disabled';
    }
    ?>
><?php 
    _e('Most viewed', 'stkit');
    ?>
</option>
					<option value="most_commented" <?php 
    if ($type == 'most_commented') {
        echo 'selected';
    }
    ?>
><?php 
    _e('Most commented', 'stkit');
    ?>
</option>
				</select>
				<p>
					<small><?php 
    _e('Select a kind of posts.', 'stkit');
    ?>
</small>
					<?php 
    if (empty($st_Settings['post_views']) || !empty($st_Settings['post_views']) && $st_Settings['post_views'] != 'yes') {
        echo '<small>' . __("Checkbox <a href='admin.php?page=st-major-settings'>Post Views</a> in case you'd like to show a most viewed posts.", 'stkit') . '</small>';
    }
    ?>
				</p>


				<div class="clear"><!-- --></div>


				<select name="<?php 
    echo $prefix . '[' . $number;
    ?>
][timeframe]">
					<option value="all" <?php 
    if ($timeframe == 'all') {
        echo 'selected';
    }
    ?>
><?php 
    _e('For all time', 'stkit');
    ?>
</option>
					<option value="month" <?php 
    if ($timeframe == 'year') {
        echo 'selected';
    }
    ?>
><?php 
    _e('For last year', 'stkit');
    ?>
</option>
					<option value="month" <?php 
    if ($timeframe == 'month') {
        echo 'selected';
    }
    ?>
><?php 
    _e('For last month', 'stkit');
    ?>
</option>
					<option value="week" <?php 
    if ($timeframe == 'week') {
        echo 'selected';
    }
    ?>
><?php 
    _e('For last week', 'stkit');
    ?>
</option>
				</select>
				<p>
					<small><?php 
    _e('Select a time frame.', 'stkit');
    ?>
</small>
				</p>


				<div class="clear"><!-- --></div>


				<input type="text" name="<?php 
    echo $prefix . '[' . $number;
    ?>
][cats]" value="<?php 
    echo $cats;
    ?>
" />
				<p><small><?php 
    _e('Enter a slugs of categories separated by comma. Optional.', 'stkit');
    ?>
</small></p>


				<div class="clear"><!-- --></div>


				<select name="<?php 
    echo $prefix . '[' . $number;
    ?>
][qty]">
					<?php 
    $arr = array(1, 2, 3, 5, 7, 10, 15);
    foreach ($arr as $value) {
        $out = '<option value="' . $value . '"';
        if ($qty == $value) {
            $out .= ' selected';
        }
        $out .= '>' . $value . '</option>';
        echo $out;
    }
    ?>
				</select>
				<p><small><?php 
    _e('Select a number of posts.', 'stkit');
    ?>
</small></p>


				<div class="clear"><!-- --></div>


				<label><input type="checkbox" name="<?php 
    echo $prefix . '[' . $number;
    ?>
][thumb]" value="display" <?php 
    if ($thumb == 'display') {
        echo 'checked';
    }
    ?>
 /> <?php 
    _e('Thumbnail', 'stkit');
    ?>
</label>


				<div class="clear"><!-- --></div>


				<label><input type="checkbox" name="<?php 
    echo $prefix . '[' . $number;
    ?>
][date]" value="display" <?php 
    if ($date == 'display') {
        echo 'checked';
    }
    ?>
 /> <?php 
    _e('Date', 'stkit');
    ?>
</label>


				<div class="clear"><!-- --></div>


				<label><input type="checkbox" name="<?php 
    echo $prefix . '[' . $number;
    ?>
][excerpt]" value="display" <?php 
    if ($excerpt == 'display') {
        echo 'checked';
    }
    ?>
 /> <?php 
    _e('Excerpt', 'stkit');
    ?>
</label>


				<div class="clear"><!-- --></div>
	
			</fieldset>

			<fieldset class="panel-fieldset metabox-fieldset">
				<legend><?php 
    _e('Misc', 'stkit');
    ?>
</legend>
	
				<label><input type="checkbox" name="<?php 
    echo $prefix . '[' . $number;
    ?>
][cache]" value="display" <?php 
    if ($cache == 'display') {
        echo 'checked';
    }
    ?>
 /> <?php 
    _e('Cache', 'stkit');
    ?>
</label>
				<small><?php 
    _e('Store a query result within 12 hours. Recommended.', 'stkit');
    ?>
</small>
	
				<div class="clear"><!-- --></div>
			</fieldset>

		<?php 
}
Exemplo n.º 2
0
function widget_flickr_multi_control($args)
{
    $prefix = 'flickr-multi';
    $options = get_option('widget_flickr_multi');
    if (empty($options)) {
        $options = array();
    }
    if (isset($options[0])) {
        unset($options[0]);
    }
    // update options array
    if (!empty($_POST[$prefix]) && is_array($_POST)) {
        foreach ($_POST[$prefix] as $widget_number => $values) {
            if (empty($values) && isset($options[$widget_number])) {
                // user clicked cancel
                continue;
            }
            if (!isset($options[$widget_number]) && $args['number'] == -1) {
                $args['number'] = $widget_number;
                $options['last_number'] = $widget_number;
            }
            $options[$widget_number] = $values;
        }
        // update number
        if ($args['number'] == -1 && !empty($options['last_number'])) {
            $args['number'] = $options['last_number'];
        }
        // clear unused options and update options in DB. return actual options array
        $options = st_smart_multiwidget_update($prefix, $options, $_POST[$prefix], $_POST['sidebar'], 'widget_flickr_multi');
    }
    $number = $args['number'] == -1 ? '%i%' : $args['number'];
    // Vars
    $opts = @$options[$number];
    $title = @$opts['title'];
    $id = @$opts['id'] ? @$opts['id'] : '52617155@N08';
    $type = @$opts['type'] ? @$opts['type'] : 'user';
    $qty = @$opts['qty'] ? @$opts['qty'] : 6;
    $order = @$opts['order'];
    ?>
	
			<fieldset class="panel-fieldset metabox-fieldset">
				<legend><?php 
    _e('Widget', 'stkit');
    ?>
</legend>

					<dl>
						<dt>
							<span><?php 
    _e('Title', 'stkit');
    ?>
</span>
						</dt>
						<dd>
							<input type="text" name="<?php 
    echo $prefix . '[' . $number;
    ?>
][title]" value="<?php 
    echo $title;
    ?>
" />
							<small><?php 
    _e('Widget title.', 'stkit');
    ?>
</small>
						</dd>
					</dl>

				<div class="clear"><!-- --></div>
			</fieldset>
		
			<fieldset class="panel-fieldset metabox-fieldset">
				<legend><?php 
    _e('Flickr', 'stkit');
    ?>
</legend>
		
					<dl>
						<dt>
							<span><?php 
    _e('Account ID', 'stkit');
    ?>
</span>
						</dt>
						<dd>
							<input type="text" name="<?php 
    echo $prefix . '[' . $number;
    ?>
][id]" value="<?php 
    echo $id;
    ?>
" />
							<p><small><?php 
    _e('Enter your Flickr ID', 'stkit');
    ?>
 (<a href="http://www.idgettr.com">idGettr</a>).</small></p>
						</dd>
					</dl>
		
					<div class="clear"><!-- --></div>
		
					<dl>
						<dt>
							<?php 
    _e('Account type', 'stkit');
    ?>
						</dt>
						<dd>
							<label><input type="radio" value="user" name="<?php 
    echo $prefix . '[' . $number;
    ?>
][type]" <?php 
    if ($type == "user" || !$type) {
        echo 'checked="checked"';
    }
    ?>
 /> <?php 
    _e('User', 'stkit');
    ?>
</label>
							<label><input type="radio" value="group" name="<?php 
    echo $prefix . '[' . $number;
    ?>
][type]" <?php 
    if ($type == "group") {
        echo 'checked="checked"';
    }
    ?>
 /> <?php 
    _e('Group', 'stkit');
    ?>
</label>
						</dd>
					</dl>
		
					<div class="clear"><!-- --></div>
		
			</fieldset>
		
			<fieldset class="panel-fieldset metabox-fieldset"><legend><?php 
    _e('Photos', 'stkit');
    ?>
</legend>
		
					<dl>
						<dt>
							<span><?php 
    _e('Quantity', 'stkit');
    ?>
</span>
						</dt>
						<dd>
							<select name="<?php 
    echo $prefix . '[' . $number;
    ?>
][qty]">
								<?php 
    $arr = array(1, 2, 3, 4, 5, 6, 7, 8, 9, 10);
    foreach ($arr as $value) {
        $out = '<option value="' . $value . '"';
        if ($qty == $value) {
            $out .= ' selected';
        }
        $out .= '>' . $value . ' &nbsp;</option>';
        echo $out;
    }
    ?>
							</select>
							<p><small><?php 
    _e('Select number of photos.', 'stkit');
    ?>
</small></p>
						</dd>
					</dl>
		
				<div class="clear"><!-- --></div>
		
					<dl>
						<dt>
							<?php 
    _e('Order', 'stkit');
    ?>
						</dt>
						<dd>
							<label><input type="radio" value="random" name="<?php 
    echo $prefix . '[' . $number;
    ?>
][order]" <?php 
    if ($order == "random" || !$order) {
        echo 'checked="checked"';
    }
    ?>
 /> <?php 
    _e('Random', 'stkit');
    ?>
</label>
							<label><input type="radio" value="latest" name="<?php 
    echo $prefix . '[' . $number;
    ?>
][order]" <?php 
    if ($order == "latest") {
        echo 'checked="checked"';
    }
    ?>
 /> <?php 
    _e('Recent', 'stkit');
    ?>
</label>
						</dd>
					</dl>
		
				<div class="clear"><!-- --></div>
		
			</fieldset>
	
		<?php 
}
Exemplo n.º 3
0
function widget_contact_info_multi_control($args)
{
    $prefix = 'contact_info-multi';
    $options = get_option('widget_contact_info_multi');
    if (empty($options)) {
        $options = array();
    }
    if (isset($options[0])) {
        unset($options[0]);
    }
    if (!empty($_POST[$prefix]) && is_array($_POST)) {
        foreach ($_POST[$prefix] as $widget_number => $values) {
            if (empty($values) && isset($options[$widget_number])) {
                // user clicked cancel
                continue;
            }
            if (!isset($options[$widget_number]) && $args['number'] == -1) {
                $args['number'] = $widget_number;
                $options['last_number'] = $widget_number;
            }
            $options[$widget_number] = $values;
        }
        // update number
        if ($args['number'] == -1 && !empty($options['last_number'])) {
            $args['number'] = $options['last_number'];
        }
        // clear unused options and update options in DB. return actual options array
        $options = st_smart_multiwidget_update($prefix, $options, $_POST[$prefix], $_POST['sidebar'], 'widget_contact_info_multi');
    }
    $number = $args['number'] == -1 ? '%i%' : $args['number'];
    // Vars
    $opts = @$options[$number];
    $title = stripslashes(@$opts['title']);
    $intro = stripslashes(@$opts['intro']);
    $phone = stripslashes(@$opts['phone']);
    $email = stripslashes(@$opts['email']);
    $address = stripslashes(@$opts['address']);
    $name = stripslashes(@$opts['name']);
    ?>

			<fieldset class="panel-fieldset metabox-fieldset">
				<legend><?php 
    _e('Widget', 'stkit');
    ?>
</legend>

					<dl>
						<dt>
							<span><?php 
    _e('Title', 'stkit');
    ?>
</span>
						</dt>
						<dd>
							<input type="text" name="<?php 
    echo $prefix . '[' . $number;
    ?>
][title]" value="<?php 
    echo $title;
    ?>
" />
							<small><?php 
    _e('Widget title.', 'stkit');
    ?>
</small>
						</dd>
					</dl>

				<div class="clear"><!-- --></div>
			</fieldset>

			<fieldset class="panel-fieldset metabox-fieldset">
				<legend><?php 
    _e('Contacts', 'stkit');
    ?>
</legend>

					<!-- Introduce -->

						<textarea class="no-resize" rows="4" cols="20" name="<?php 
    echo $prefix . '[' . $number;
    ?>
][intro]" ><?php 
    echo $intro;
    ?>
</textarea>
						<p><small><?php 
    _e('Enter an introduce text or leave it blank.', 'stkit');
    ?>
</small></p>
						<div class="clear"><!-- --></div>


					<!-- Address -->

						<dl>
							<dt>
								<span><?php 
    _e('Address', 'stkit');
    ?>
</span>
							</dt>
							<dd>
								<input type="text" name="<?php 
    echo $prefix . '[' . $number;
    ?>
][address]" value="<?php 
    echo $address;
    ?>
" />
								<div class="clear"><!-- --></div>			
							</dd>
						</dl>


					<!-- Phone -->

						<dl>
							<dt>
								<span><?php 
    _e('Phone', 'stkit');
    ?>
</span>
							</dt>
							<dd>
								<input type="text" name="<?php 
    echo $prefix . '[' . $number;
    ?>
][phone]" value="<?php 
    echo $phone;
    ?>
" />
								<div class="clear"><!-- --></div>
							</dd>
						</dl>


					<!-- Email -->

						<dl>
							<dt>
								<span><?php 
    _e('Email', 'stkit');
    ?>
</span>
							</dt>
							<dd>
								<input type="text" name="<?php 
    echo $prefix . '[' . $number;
    ?>
][email]" value="<?php 
    echo $email;
    ?>
" />
								<div class="clear"><!-- --></div>
							</dd>
						</dl>


					<!-- Name -->

						<dl>
							<dt>
								<span><?php 
    _e('Name', 'stkit');
    ?>
</span>
							</dt>
							<dd>
								<input type="text" name="<?php 
    echo $prefix . '[' . $number;
    ?>
][name]" value="<?php 
    echo $name;
    ?>
" />
							</dd>
						</dl>

				<div class="clear"><!-- --></div>
			</fieldset>

		<?php 
}
Exemplo n.º 4
0
function widget_subscribe_multi_control($args)
{
    $prefix = 'subscribe-multi';
    $options = get_option('widget_subscribe_multi');
    if (empty($options)) {
        $options = array();
    }
    if (isset($options[0])) {
        unset($options[0]);
    }
    // update options array
    if (!empty($_POST[$prefix]) && is_array($_POST)) {
        foreach ($_POST[$prefix] as $widget_number => $values) {
            if (empty($values) && isset($options[$widget_number])) {
                // user clicked cancel
                continue;
            }
            if (!isset($options[$widget_number]) && $args['number'] == -1) {
                $args['number'] = $widget_number;
                $options['last_number'] = $widget_number;
            }
            $options[$widget_number] = $values;
        }
        // update number
        if ($args['number'] == -1 && !empty($options['last_number'])) {
            $args['number'] = $options['last_number'];
        }
        // clear unused options and update options in DB. return actual options array
        $options = st_smart_multiwidget_update($prefix, $options, $_POST[$prefix], $_POST['sidebar'], 'widget_subscribe_multi');
    }
    $number = $args['number'] == -1 ? '%i%' : $args['number'];
    // Vars
    $opts = @$options[$number];
    $title = @$opts['title'];
    $feedId = @$opts['feedId'];
    $descr = @$opts['descr'] ? stripslashes(@$opts['descr']) : __('Sign up for our newsletter to receive the latest news and event postings.', 'stkit');
    ?>

			<fieldset class="panel-fieldset metabox-fieldset"><legend><?php 
    _e('Title', 'stkit');
    ?>
</legend>

				<input type="text" name="<?php 
    echo $prefix . '[' . $number;
    ?>
][title]" value="<?php 
    echo $title;
    ?>
" />
				<small><?php 
    _e('Widget title.', 'stkit');
    ?>
</small>

			</fieldset>

			<fieldset class="panel-fieldset metabox-fieldset">
				<legend><?php 
    _e('Feedburner', 'stkit');
    ?>
</legend>
		
				<input type="text" name="<?php 
    echo $prefix . '[' . $number;
    ?>
][feedId]" value="<?php 
    echo $feedId;
    ?>
" />
				<small><?php 
    _e('Enter you Feedburner ID', 'stkit');
    ?>
</small>
		
				<div class="clear"><!-- --></div>
			</fieldset>
		
			<fieldset class="panel-fieldset metabox-fieldset">
				<legend><?php 
    _e('Email-subscribe', 'stkit');
    ?>
</legend>

				<textarea rows="4" cols="20" name="<?php 
    echo $prefix . '[' . $number;
    ?>
][descr]" ><?php 
    echo $descr;
    ?>
</textarea>
				<small><?php 
    _e('Description', 'stkit');
    ?>
</small>
		
				<div class="clear"><!-- --></div>
		
			</fieldset>
	
		<?php 
}
Exemplo n.º 5
0
function widget_social_icons_multi_control($args)
{
    $prefix = 'social_icons-multi';
    $options = get_option('widget_social_icons_multi');
    if (empty($options)) {
        $options = array();
    }
    if (isset($options[0])) {
        unset($options[0]);
    }
    // update options array
    if (!empty($_POST[$prefix]) && is_array($_POST)) {
        foreach ($_POST[$prefix] as $widget_number => $values) {
            if (empty($values) && isset($options[$widget_number])) {
                // user clicked cancel
                continue;
            }
            if (!isset($options[$widget_number]) && $args['number'] == -1) {
                $args['number'] = $widget_number;
                $options['last_number'] = $widget_number;
            }
            $options[$widget_number] = $values;
        }
        // update number
        if ($args['number'] == -1 && !empty($options['last_number'])) {
            $args['number'] = $options['last_number'];
        }
        // clear unused options and update options in DB. return actual options array
        $options = st_smart_multiwidget_update($prefix, $options, $_POST[$prefix], $_POST['sidebar'], 'widget_social_icons_multi');
    }
    $number = $args['number'] == -1 ? '%i%' : $args['number'];
    // Vars
    $opts = @$options[$number];
    $title = @$opts['title'];
    ?>
	
			<fieldset class="panel-fieldset metabox-fieldset">
				<legend><?php 
    _e('Title', 'stkit');
    ?>
</legend>
		
				<input type="text" name="<?php 
    echo $prefix . '[' . $number;
    ?>
][title]" value="<?php 
    echo $title;
    ?>
" />
				<small><?php 
    _e('Widget title.', 'stkit');
    ?>
</small>
		
				<div class="clear"><!-- --></div>
			</fieldset>
		
			<fieldset class="panel-fieldset metabox-fieldset">
				<legend><?php 
    _e('Icons', 'stkit');
    ?>
</legend>

				<a href="admin.php?page=st-layout-settings" class="button"><?php 
    _e('Manage', 'stkit');
    ?>
</a>
				<small><?php 
    _e('Fill forms on Social tab.', 'stkit');
    ?>
</small>
		
				<div class="clear"><!-- --></div>
		
			</fieldset>
	
		<?php 
}
Exemplo n.º 6
0
function widget_adsense_multi_control($args)
{
    $prefix = 'adsense-multi';
    $options = get_option('widget_adsense_multi');
    if (empty($options)) {
        $options = array();
    }
    if (isset($options[0])) {
        unset($options[0]);
    }
    if (!empty($_POST[$prefix]) && is_array($_POST)) {
        foreach ($_POST[$prefix] as $widget_number => $values) {
            if (empty($values) && isset($options[$widget_number])) {
                // user clicked cancel
                continue;
            }
            if (!isset($options[$widget_number]) && $args['number'] == -1) {
                $args['number'] = $widget_number;
                $options['last_number'] = $widget_number;
            }
            $options[$widget_number] = $values;
        }
        // update number
        if ($args['number'] == -1 && !empty($options['last_number'])) {
            $args['number'] = $options['last_number'];
        }
        // clear unused options and update options in DB. return actual options array
        $options = st_smart_multiwidget_update($prefix, $options, $_POST[$prefix], $_POST['sidebar'], 'widget_adsense_multi');
    }
    $number = $args['number'] == -1 ? '%i%' : $args['number'];
    // Vars
    $opts = @$options[$number];
    $slot = @$opts['slot'];
    $type = @$opts['type'] ? @$opts['type'] : array();
    // Sizes
    $sizes = array('980x120', '970x90', '930x180', '750x300', '750x200', '750x100', '728x90', '580x400', '468x60', '336x280', '320x100', '320x50', '300x600', '300x250', '250x360', '250x250', '240x400', '234x60', '200x200', '180x150', '160x600', '125x125', '120x600', '120x240');
    ?>

			<fieldset class="panel-fieldset metabox-fieldset">
				<legend><?php 
    _e('Slot', 'stkit');
    ?>
</legend>

					<input type="text" name="<?php 
    echo $prefix . '[' . $number;
    ?>
][slot]" value="<?php 
    echo $slot;
    ?>
" />
					<small><?php 
    _e('Ad unit slot.', 'stkit');
    ?>
</small>

				<div class="clear"><!-- --></div>
			</fieldset>

			<fieldset class="panel-fieldset metabox-fieldset">
				<legend><?php 
    _e('Sizes', 'stkit');
    ?>
</legend>

					<select multiple="multiple" name="<?php 
    echo $prefix . '[' . $number;
    ?>
][type][]">
						<?php 
    foreach ($sizes as $size) {
        $selected = '';
        foreach ($type as $value) {
            if ($size == $value) {
                $selected = ' selected';
            }
        }
        echo '<option value="' . $size . '"' . $selected . '>' . $size . '</option>';
    }
    ?>
						<?php 
    // if ( $type == 'horiz' ) echo 'selected';
    ?>
					</select>

					<small><?php 
    _e('Select the sizes.', 'stkit');
    ?>
</small>

				<div class="clear"><!-- --></div>
			</fieldset>

		<?php 
}