当前位置: 首页>>代码示例>>PHP>>正文


PHP aq_field_select函数代码示例

本文整理汇总了PHP中aq_field_select函数的典型用法代码示例。如果您正苦于以下问题:PHP aq_field_select函数的具体用法?PHP aq_field_select怎么用?PHP aq_field_select使用的例子?那么, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了aq_field_select函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: form

    function form($instance)
    {
        //get all registered sidebars
        global $wp_registered_sidebars;
        $sidebar_options = array();
        $default_sidebar = '';
        foreach ($wp_registered_sidebars as $registered_sidebar) {
            $default_sidebar = empty($default_sidebar) ? $registered_sidebar['id'] : $default_sidebar;
            $sidebar_options[$registered_sidebar['id']] = $registered_sidebar['name'];
        }
        $defaults = array('sidebar' => $default_sidebar);
        $instance = wp_parse_args($instance, $defaults);
        extract($instance);
        ?>
		<p class="description half">
			<label for="<?php 
        echo $block_id;
        ?>
_title">
				Title (optional)<br/>
				<?php 
        echo aq_field_input('title', $block_id, $title, $size = 'full');
        ?>
			</label>
		</p>
		<p class="description half last">
			<label for="">
				Choose widget area<br/>
				<?php 
        echo aq_field_select('sidebar', $block_id, $sidebar_options, $sidebar);
        ?>
			</label>
		</p>
		<?php 
    }
开发者ID:xiang-chen-git,项目名称:LeanBlog,代码行数:35,代码来源:aq-widgets-block.php

示例2: form

        function form($instance)
        {
            $defaults = array('show_row' => 'true');
            $instance = wp_parse_args($instance, $defaults);
            extract($instance);
            $row = array('true' => 'Yes', 'false' => 'No');
            ?>
		<p class="description">
			<?php 
            _e('There is no setting here. Just make sure to add this block if you use container (open).', 'oneengine');
            ?>
		</p>
        <p class="description">
			<label for="<?php 
            echo $this->get_field_id('show_row');
            ?>
">
				<?php 
            _e('Show/hide section "row" (if you add block item fullwidth here, please choose "No" for 2 block "Container (open)" and "Container (close)")', 'oneengine');
            ?>
				<?php 
            echo aq_field_select('show_row', $block_id, $row, $show_row);
            ?>
			</label>
		</p>
		<?php 
        }
开发者ID:gosferano,项目名称:wordpress,代码行数:27,代码来源:container-close.php

示例3: form

    function form($instance)
    {
        $defaults = array('type' => 'fullwidth', 'pppage' => '999', 'filter' => 'all', 'show_filter' => 1);
        $instance = wp_parse_args($instance, $defaults);
        extract($instance);
        $args = array('orderby' => 'name', 'hide_empty' => 0, 'hierarchical' => 1, 'taxonomy' => 'portfolio_category');
        $filter_options = get_categories($args);
        $portfolio_types = array('half' => 'Fullwidth Portfolio (2 Columns)', 'fullwidth' => 'Fullwidth Portfolio', 'quarter' => 'Fullwidth Portfolio (4 Columns)', 'contained' => 'Contained Portfolio');
        ?>
		
		<p class="description">Portfolio Style</p>
		<?php 
        echo aq_field_select('type', $block_id, $portfolio_types, $type);
        ?>
		
		<p class="description">Load how many items? 999 for all. <code>Note: The Portfolio is not Paged</code></p>
		<?php 
        echo aq_field_input('pppage', $block_id, $pppage, $size = 'full', $type = 'number');
        ?>
		
		<p class="description">Show a specific portfolio category?</p>
		<?php 
        echo ebor_portfolio_field_select('filter', $block_id, $filter_options, $filter);
        ?>
		
		<p class="description">Show Portfolio Filters?</p>
		<?php 
        echo aq_field_checkbox('show_filter', $block_id, $show_filter);
        ?>
		
	<?php 
    }
开发者ID:WebTM,项目名称:web,代码行数:32,代码来源:portfolio_block.php

示例4: form

    function form($instance)
    {
        $defaults = array('content' => '', 'type' => '', 'format' => 'dismiss');
        $instance = wp_parse_args($instance, $defaults);
        extract($instance);
        $type_options = array('alert-warning' => 'Standard', 'alert-danger' => 'Error', 'alert-success' => 'Success', 'alert-info' => 'Info');
        $format_options = array('standard' => 'Standard Alert', 'dismiss' => 'Alert with Dismiss');
        ?>
		
		<p class="description">
			<label for="<?php 
        echo $this->get_field_id('title');
        ?>
">
				Title (optional)<br/>
				<?php 
        echo aq_field_input('title', $block_id, $title);
        ?>
			</label>
		</p>
		
		<p class="description">
			<label for="<?php 
        echo $this->get_field_id('content');
        ?>
">
				Alert Text (required)<br/>
				<?php 
        echo aq_field_textarea('content', $block_id, $content);
        ?>
			</label>
		</p>
		
		<p class="description half">
			<label for="<?php 
        echo $this->get_field_id('type');
        ?>
">
				Alert Type<br/>
				<?php 
        echo aq_field_select('type', $block_id, $type_options, $type);
        ?>
			</label>
		</p>
		
		<p class="description half">
			<label for="<?php 
        echo $this->get_field_id('format');
        ?>
">
				Alert Format<br/>
				<?php 
        echo aq_field_select('format', $block_id, $format_options, $format);
        ?>
			</label>
		</p>

	<?php 
    }
开发者ID:misfist,项目名称:loom-theme,代码行数:59,代码来源:alert_block.php

示例5: form

    function form($instance)
    {
        $defaults = array('tabs' => array(1 => array('title' => 'My New Tab', 'content' => 'My tab contents')), 'type' => 'tab', 'text' => '');
        $instance = wp_parse_args($instance, $defaults);
        extract($instance);
        $tab_types = array('tab' => 'Tabs', 'toggle' => 'Toggles');
        ?>
		
		<p class="description">
			<label for="<?php 
        echo $this->get_field_id('title');
        ?>
">
				Block Title (optional)
				<?php 
        echo aq_field_input('title', $block_id, $title, $size = 'full');
        ?>
			</label>
		</p>

		<p class="description">
			<label for="<?php 
        echo $this->get_field_id('type');
        ?>
">
				Tabs style<br/>
				<?php 
        echo aq_field_select('type', $block_id, $tab_types, $type);
        ?>
			</label>
		</p>
		
		<div class="description cf">
			<ul id="aq-sortable-list-<?php 
        echo $block_id;
        ?>
" class="aq-sortable-list" rel="<?php 
        echo $block_id;
        ?>
">
				<?php 
        $tabs = is_array($tabs) ? $tabs : $defaults['tabs'];
        $count = 1;
        foreach ($tabs as $tab) {
            $this->tab($tab, $count);
            $count++;
        }
        ?>
			</ul>
			<p></p>
			<a href="#" rel="tab" class="aq-sortable-add-new button">Add New</a>
			<p></p>
		</div>
		
	<?php 
    }
开发者ID:misfist,项目名称:loom-theme,代码行数:56,代码来源:tabs_block.php

示例6: form

        function form($instance)
        {
            $defaults = array('content' => '', 'type' => 'note', 'style' => '');
            $instance = wp_parse_args($instance, $defaults);
            extract($instance);
            $type_options = array('default' => 'Standard', 'info' => 'Info', 'note' => 'Notification', 'warn' => 'Warning', 'tips' => 'Tips');
            ?>
			
			<p class="description">
				<label for="<?php 
            echo $this->get_field_id('title');
            ?>
">
					Title (optional)<br/>
					<?php 
            echo aq_field_input('title', $block_id, $title);
            ?>
				</label>
			</p>
			<p class="description">
				<label for="<?php 
            echo $this->get_field_id('content');
            ?>
">
					Alert Text (required)<br/>
					<?php 
            echo aq_field_textarea('content', $block_id, $content);
            ?>
				</label>
			</p>
			<p class="description half">
				<label for="<?php 
            echo $this->get_field_id('type');
            ?>
">
					Alert Type<br/>
					<?php 
            echo aq_field_select('type', $block_id, $type_options, $type);
            ?>
				</label>
			</p>
			<p class="description half last">
				<label for="<?php 
            echo $this->get_field_id('style');
            ?>
">
					Additional inline css styling (optional)<br/>
					<?php 
            echo aq_field_input('style', $block_id, $style);
            ?>
				</label>
			</p>
			<?php 
        }
开发者ID:hunghoang179,项目名称:sitenews,代码行数:54,代码来源:aq-alert-block.php

示例7: form

        function form($instance)
        {
            $defaults = array('content' => '', 'type' => 'note', 'style' => '', 'wp_autop' => 1);
            $instance = wp_parse_args($instance, $defaults);
            extract($instance);
            $type_options = array('notice' => 'Notice', 'error' => 'Error', 'warning' => 'Warning', 'success' => 'Success');
            ?>

				<p class="description">
					<label for="<?php 
            echo $this->get_field_id('content');
            ?>
">
						Alert Text (required)<br/>
						<?php 
            echo aq_field_textarea('content', $block_id, $content);
            ?>
					</label>
					<label for="<?php 
            echo $this->get_field_id('wp_autop');
            ?>
">
						<?php 
            echo aq_field_checkbox('wp_autop', $block_id, $wp_autop);
            ?>
						Do not create the paragraphs automatically. <code>"wpautop"</code> disable.
					</label>
				</p>
				<p class="description half">
					<label for="<?php 
            echo $this->get_field_id('type');
            ?>
">
						Alert Type<br/>
						<?php 
            echo aq_field_select('type', $block_id, $type_options, $type);
            ?>
					</label>
				</p>
				<p class="description half last">
					<label for="<?php 
            echo $this->get_field_id('style');
            ?>
">
						Additional inline css styling (optional)<br/>
						<?php 
            echo aq_field_input('style', $block_id, $style);
            ?>
					</label>
				</p>
				<?php 
        }
开发者ID:JeffreyBue,项目名称:jb,代码行数:52,代码来源:pp-alert-block.php

示例8: form

    function form($instance)
    {
        $defaults = array('horizontal_line' => 'none', 'line_color' => '#e5e5e5', 'pattern' => '1', 'height' => '5');
        $line_options = array('none' => 'None', 'solid' => 'Solid', 'dashed' => 'Dashed', 'dotted' => 'Dotted');
        $instance = wp_parse_args($instance, $defaults);
        extract($instance);
        $line_color = isset($line_color) ? $line_color : '#353535';
        ?>
		<div class="description note">
			<?php 
        _e('Use this block to clear the floats between two or more separate blocks vertically.', 'framework');
        ?>
		</div>

		<div class="description fourth">
			<label for="<?php 
        echo $this->get_field_id('horizontal_line');
        ?>
">
				Pick a horizontal line<br/>
				<?php 
        echo aq_field_select('horizontal_line', $block_id, $line_options, $horizontal_line);
        ?>
			</label>
		</div>
		<div class="description fourth">
			<label for="<?php 
        echo $this->get_field_id('height');
        ?>
">
				Height<br/>
				<?php 
        echo aq_field_input('height', $block_id, $height, 'min', 'number');
        ?>
 px
			</label>
			
		</div>
		<div class="description half last">
			<label for="<?php 
        echo $this->get_field_id('line_color');
        ?>
">
				Pick a line color<br/>
				<?php 
        echo aq_field_color_picker('line_color', $block_id, $line_color, $defaults['line_color']);
        ?>
			</label>
			
		</div>
		<?php 
    }
开发者ID:piet89,项目名称:flexmarket,代码行数:52,代码来源:aq-separator-block.php

示例9: form

        function form($instance)
        {
            $defaults = array('limit' => '4', 'title' => 'Team', 'members' => '');
            $limit_options = array();
            for ($i = 0; $i < 25; $i++) {
                $limit_options[$i] = $i;
            }
            $wp_query = new WP_Query(array('post_type' => array('team'), 'showposts' => 99));
            $team_members = array();
            while ($wp_query->have_posts()) {
                $wp_query->the_post();
                $team_members[$wp_query->post->ID] = get_the_title();
            }
            $instance = wp_parse_args($instance, $defaults);
            extract($instance);
            ?>
            <p class="description half">
                <label for="<?php 
            echo $this->get_field_id('title');
            ?>
">
                    Title (required)<br/>
                    <?php 
            echo aq_field_input('title', $block_id, $title);
            ?>
                </label>
            </p>
            <p class="description half last">
                <label for="<?php 
            echo $this->get_field_id('limit');
            ?>
">
                    Limit (required)<br/>
                    <?php 
            echo aq_field_select('limit', $block_id, $limit_options, $limit);
            ?>
                </label>
            </p>
            <p class="description">
                <label for="<?php 
            echo $this->get_field_id('filters');
            ?>
">
                    Select members (for all leave blank)<br/>
                    <?php 
            echo aq_field_multiselect('members', $block_id, $team_members, $members);
            ?>
                </label>
            </p>

            <?php 
        }
开发者ID:JeffreyBue,项目名称:jb,代码行数:52,代码来源:pp-team-block.php

示例10: form_fields

    /**
     * Form fields, this is where we'll put every option we'll use for this block
     */
    function form_fields($instance)
    {
        $defaults = array('title' => 'The Page Section Title', 'type' => 'standard', 'image' => '', 'thin_column' => 0);
        $instance = wp_parse_args($instance, $defaults);
        extract($instance);
        if ($title == '') {
            $title = 'The Page Section Title';
        }
        $type_options = array('light-wrapper' => 'Light Background', 'dark-wrapper' => 'Dark Background', 'bg-primary' => 'Primary Highlight Colour Background', 'bg-secondary-1' => 'Secondary Highlight Colour Background', 'bg-secondary-2 ' => 'Secondary Highlight 2 Colour Background', 'image' => 'Parallax Background Image (Full Width)', 'image-left' => 'Image Left, Content on Right', 'image-right' => 'Image Right, Content on Left');
        ?>
		<div class="two_thirds">
			<p class="description">Label this page section</p>
			<?php 
        echo aq_field_input('title', $this->block_id, $title, $size = 'full');
        ?>
			
			<hr />
			
			<p class="description">Menu Link for this section: <code>#<?php 
        echo ebor_sanitize_title($title);
        ?>
</code><br />(Used for one-page version only)</p>

			<hr />
			
			<p class="description">Use thin column content width for this section?</p>
			<?php 
        echo aq_field_checkbox('thin_column', $this->block_id, $thin_column);
        ?>

		</div>
		
		<div class="one_third last">	
			
			<p class="description">Background Type</p>
			<?php 
        echo aq_field_select('type', $this->block_id, $type_options, $type);
        ?>
			
			<hr />
			
			<p class="description">Image for Parallax Background</p>
			<?php 
        echo aq_field_upload('image', $this->block_id, $image, $media_type = 'image');
        ?>

		</div>
		<div class="clear"></div>
	<?php 
    }
开发者ID:WebTM,项目名称:web,代码行数:53,代码来源:page_section_block.php

示例11: form

    function form($instance)
    {
        $defaults = array('horizontal_line' => 'none', 'line_color' => '#FFFFFF', 'pattern' => '1', 'height' => '');
        $line_options = array('transparent' => 'Trasparent', 'colored' => 'Colored', 'colored_alt' => 'Colored (No Margins)');
        $instance = wp_parse_args($instance, $defaults);
        extract($instance);
        $line_color = isset($line_color) ? $line_color : '#ededed';
        ?>
		<p class="description note">
			<?php 
        _e('Use this block to clear the floats between two or more separate blocks vertically.', 'themnific');
        ?>
		</p>
		<p class="description fourth">
			<label for="<?php 
        echo $this->get_field_id('line_color');
        ?>
">
				Pick a horizontal line<br/>
				<?php 
        echo aq_field_select('horizontal_line', $block_id, $line_options, $horizontal_line, $block_id);
        ?>
			</label>
		</p>
		<div class="description fourth">
			<label for="<?php 
        echo $this->get_field_id('height');
        ?>
">
				Height (optional)<br/>
				<?php 
        echo aq_field_input('height', $block_id, $height, 'min', 'number');
        ?>
 px
			</label>
		</div>
		<div class="description half last">
			<label for="<?php 
        echo $this->get_field_id('line_color');
        ?>
">
				Pick a line color<br/>
				<?php 
        echo aq_field_color_picker('line_color', $block_id, $line_color, $defaults['line_color']);
        ?>
			</label>
			
		</div>
		<?php 
    }
开发者ID:xiang-chen-git,项目名称:LeanBlog,代码行数:50,代码来源:aq-clear-block.php

示例12: form

    function form($instance)
    {
        $defaults = array('horizontal_line' => 'none', 'line_color' => '#353535', 'pattern' => '1', 'height' => '');
        $line_options = array('none' => 'None', 'single' => 'Single', 'double' => 'Double', 'image' => 'Use Image');
        $instance = wp_parse_args($instance, $defaults);
        extract($instance);
        $line_color = isset($line_color) ? $line_color : '#353535';
        ?>
		<p class="description note">
			<?php 
        _e('Use this block to clear the floats between two or more separate blocks vertically.', 'framework');
        ?>
		</p>
		<p class="description third">
			<label for="<?php 
        echo $this->get_field_id('line_color');
        ?>
">
				Pick a horizontal line<br/>
				<?php 
        echo aq_field_select('horizontal_line', $block_id, $line_options, $horizontal_line, $block_id);
        ?>
			</label>
		</p>
		<div class="description third">
			<label for="<?php 
        echo $this->get_field_id('line_color');
        ?>
">
				Pick a line color<br/>
				<?php 
        echo aq_field_color_picker('line_color', $block_id, $line_color);
        ?>
			</label>
			
		</div>
		<div class="description third last">
			<label for="<?php 
        echo $this->get_field_id('height');
        ?>
">
				Height (optional)<br/>
				<?php 
        echo aq_field_input('height', $block_id, $height, 'min', 'number');
        ?>
			</label>
			
		</div>
		<?php 
    }
开发者ID:rvision,项目名称:Aqua-Page-Builder,代码行数:50,代码来源:aq-clear-block.php

示例13: form

    function form($instance)
    {
        $defaults = array('layout' => '4col', 'entries' => '4', 'excerpt' => '100');
        $instance = wp_parse_args($instance, $defaults);
        extract($instance);
        $layout_options = array('2col' => '2 Columns', '3col' => '3 Columns', '4col' => '4 Columns');
        $entries_options = array('2' => '2', '3' => '3', '4' => '4', '5' => '5', '6' => '6', '7' => '7', '8' => '8', '9' => '9', '10' => '10', '11' => '11', '12' => '12', '13' => '13', '14' => '14', '15' => '15', '16' => '16', '17' => '17', '18' => '18', '19' => '19', '20' => '20');
        ?>

		<div class="description half">
			<label for="<?php 
        echo $this->get_field_id('layout');
        ?>
">
				Layout<br/>
				<?php 
        echo aq_field_select('layout', $block_id, $layout_options, $layout);
        ?>
			</label>
		</div>

		<div class="description half last">
			<label for="<?php 
        echo $this->get_field_id('entries');
        ?>
">
				Number of Entries<br/>
				<?php 
        echo aq_field_select('entries', $block_id, $entries_options, $entries);
        ?>
			</label>
		</div>

		<div class="description half">
			<label for="<?php 
        echo $this->get_field_id('excerpt');
        ?>
">
				Maximum Character in Excerpt<br/>
				<?php 
        echo aq_field_input('excerpt', $block_id, $excerpt, $size = 'full');
        ?>
				<em style="padding-left: 5px; font-size: 0.75em;">Leave it blank or enter "0" to disable excerpt.</em>
			</label>
		</div>
		
		<?php 
    }
开发者ID:piet89,项目名称:flexmarket,代码行数:48,代码来源:aq-blog-block.php

示例14: form

    function form($instance)
    {
        $defaults = array('pppage' => '6', 'filter' => 'all', 'type' => 'blogsidebar');
        $instance = wp_parse_args($instance, $defaults);
        extract($instance);
        $args = array('orderby' => 'name', 'hide_empty' => 0, 'hierarchical' => 1, 'taxonomy' => 'category');
        $filter_options = get_categories($args);
        $blog_types = array('blogsidebar' => 'Sidebar Blog', 'blognosidebar' => 'No Sidebar Blog', 'blogshowcase' => 'Showcase (full screen grid) blog');
        ?>
		
		<p class="description">
			<label for="<?php 
        echo $this->get_field_id('type');
        ?>
">
				Blog Style
				<?php 
        echo aq_field_select('type', $block_id, $blog_types, $type);
        ?>
			</label>
		</p>
		
		<p class="description">
			<label for="<?php 
        echo $this->get_field_id('pppage');
        ?>
">
				Posts Per Page
				<?php 
        echo aq_field_input('pppage', $block_id, $pppage, $size = 'full', $type = 'number');
        ?>
			</label>
		</p>
		
		<p class="description">
			<label for="<?php 
        echo $this->get_field_id('filter');
        ?>
">
				Show posts from a specific category? (Leave as "All" if using the showcase layout)<br />
				<?php 
        echo ebor_portfolio_field_select('filter', $block_id, $filter_options, $filter);
        ?>
			</label>
		</p>
		
	<?php 
    }
开发者ID:carinaoliveira,项目名称:template2016,代码行数:48,代码来源:blog_block.php

示例15: form

    function form($instance)
    {
        $defaults = array('pppage' => '6', 'filter' => 'all', 'layout' => 'feed');
        $instance = wp_parse_args($instance, $defaults);
        extract($instance);
        $args = array('orderby' => 'name', 'hide_empty' => 0, 'hierarchical' => 1, 'taxonomy' => 'team-category');
        $filter_options = get_categories($args);
        $layout_options = array('feed' => 'Team Feed', 'grid' => 'Team Grid');
        ?>
		
		<p class="description">
			<label for="<?php 
        echo $this->get_field_id('layout');
        ?>
">
				Team Style
				<?php 
        echo aq_field_select('layout', $block_id, $layout_options, $layout);
        ?>
			</label>
		</p>
		
		<p class="description">
			<label for="<?php 
        echo $this->get_field_id('pppage');
        ?>
">
				Posts Per Page
				<?php 
        echo aq_field_input('pppage', $block_id, $pppage, $size = 'full', $type = 'number');
        ?>
			</label>
		</p>
		
		<p class="description">
			<label for="<?php 
        echo $this->get_field_id('filter');
        ?>
">
				Show a specific Team Category?
				<?php 
        echo ebor_portfolio_field_select('filter', $block_id, $filter_options, $filter);
        ?>
			</label>
		</p>
		
	<?php 
    }
开发者ID:misfist,项目名称:loom-theme,代码行数:48,代码来源:team_feed_block.php


注:本文中的aq_field_select函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。