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


PHP FLBuilderModel::default_settings方法代码示例

本文整理汇总了PHP中FLBuilderModel::default_settings方法的典型用法代码示例。如果您正苦于以下问题:PHP FLBuilderModel::default_settings方法的具体用法?PHP FLBuilderModel::default_settings怎么用?PHP FLBuilderModel::default_settings使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在FLBuilderModel的用法示例。


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

示例1: array

<?php

FLBuilderModel::default_settings($settings, array('post_type' => 'post', 'order_by' => 'date', 'order' => 'DESC', 'offset' => 0, 'users' => ''));
?>
<div id="fl-builder-settings-section-general" class="fl-loop-builder fl-builder-settings-section">

	<table class="fl-form-table">
	<?php 
// Post type
FLBuilder::render_settings_field('post_type', array('type' => 'post-type', 'label' => __('Post Type', 'fl-builder')), $settings);
// Order by
FLBuilder::render_settings_field('order_by', array('type' => 'select', 'label' => __('Order By', 'fl-builder'), 'options' => array('ID' => __('ID', 'fl-builder'), 'date' => __('Date', 'fl-builder'), 'modified' => __('Date Last Modified', 'fl-builder'), 'title' => __('Title', 'fl-builder'), 'author' => __('Author', 'fl-builder'), 'comment_count' => __('Comment Count', 'fl-builder'), 'menu_order' => __('Menu Order', 'fl-builder'), 'rand' => __('Random', 'fl-builder'))), $settings);
// Order
FLBuilder::render_settings_field('order', array('type' => 'select', 'label' => __('Order', 'fl-builder'), 'options' => array('DESC' => __('Descending', 'fl-builder'), 'ASC' => __('Ascending', 'fl-builder'))), $settings);
// Offset
FLBuilder::render_settings_field('offset', array('type' => 'text', 'label' => _x('Offset', 'How many posts to skip.', 'fl-builder'), 'default' => '0', 'size' => '4', 'help' => __('Skip this many posts that match the specified criteria.', 'fl-builder')), $settings);
?>
	</table>
</div>
<div id="fl-builder-settings-section-filter" class="fl-builder-settings-section">
	<h3 class="fl-builder-settings-title"><?php 
_e('Filter', 'fl-builder');
?>
</h3>
	<?php 
foreach (FLBuilderLoop::post_types() as $slug => $type) {
    ?>
		<table class="fl-form-table fl-loop-builder-filter fl-loop-builder-<?php 
    echo $slug;
    ?>
-filter" <?php 
开发者ID:nullality,项目名称:FEWD-SEA-7,代码行数:31,代码来源:loop-settings.php


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