PHPackages                             sectsect/cfs-loop-field-query - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. sectsect/cfs-loop-field-query

ActiveWordpress-plugin

sectsect/cfs-loop-field-query
=============================

Modify the Query to Multiple Dates in a post For Custom Field Suite 'Loop Field'.

v2.1.5(8y ago)1101MITPHPPHP &gt;=5.3

Since Jan 31Pushed 6y ago2 watchersCompare

[ Source](https://github.com/sectsect/cfs-loop-field-query)[ Packagist](https://packagist.org/packages/sectsect/cfs-loop-field-query)[ RSS](/packages/sectsect-cfs-loop-field-query/feed)WikiDiscussions master Synced 2mo ago

READMEChangelogDependenciesVersions (10)Used By (0)

[![](https://camo.githubusercontent.com/b8a22d292780c631360a84efd912e57855d5395021965174bffa6f3b255dd62f/68747470733a2f2f6769746875622d736563742e73332d61702d6e6f727468656173742d312e616d617a6f6e6177732e636f6d2f6c6f676f2e737667)](https://camo.githubusercontent.com/b8a22d292780c631360a84efd912e57855d5395021965174bffa6f3b255dd62f/68747470733a2f2f6769746875622d736563742e73332d61702d6e6f727468656173742d312e616d617a6f6e6177732e636f6d2f6c6f676f2e737667) CFS Loop Field Query - For Events -
=====================================================================================================================================================================================================================================================================================================================================================================================================================================================================================================

[](#-cfs-loop-field-query---for-events--)

### Modify the Query to multiple dates in a post For [Custom Field Suite](https://wordpress.org/plugins/custom-field-suite/) "Loop Field".

[](#modify-the-query-to-multiple-dates-in-a-post-for-custom-field-suite-loop-field)

Features
--------

[](#features)

For each `Date and Time` set in the `Loop Field`, only the scheduled events are output to Archive Page.

- The `Date and Time` set in the `Loop Field` is outputted as `one event`.
- Displayed in order of the most recent event (`ASC`).
- Closed events is not outputted.
- Supply a `function` for calendar 📅

Requirements
------------

[](#requirements)

- PHP 5.3+
- Activation [Custom Field Suite](https://wordpress.org/plugins/custom-field-suite/) Plugin.
- Create a Loop Field and Date Field in the Loop Field using [CFS](https://wordpress.org/plugins/custom-field-suite/) Plugin.
- A 6-pack of beer🍺 (optional, I guess.)

Installation
------------

[](#installation)

1. `cd /path-to-your/wp-content/plugins/`
2. `git clone git@github.com:sectsect/cfs-loop-field-query.git`
3. Activate the plugin through the 'Plugins' menu in WordPress.
    You can access the some setting by going to `Settings` -&gt; `CFS Loop Field Query`.
4. Setting `Post Type Name`, `Loop Field Name`, `Date Field Name` in Loop Feld".
    ( Optional Field: `Taxonomy Name`, `StartTime Field`, `FinishTime Field` )
    That's it:ok\_hand: The main query of your select post types will be modified.

Fields Structure Example
------------------------

[](#fields-structure-example)

[![](https://camo.githubusercontent.com/a77146a79d93efa06f22808dc7307a9ae76ceb78d12e9e430c17de2fac84808f/68747470733a2f2f6769746875622d736563742e73332d61702d6e6f727468656173742d312e616d617a6f6e6177732e636f6d2f6366732d6c6f6f702d6669656c642d71756572792f73637265656e73686f742e706e67)](https://camo.githubusercontent.com/a77146a79d93efa06f22808dc7307a9ae76ceb78d12e9e430c17de2fac84808f/68747470733a2f2f6769746875622d736563742e73332d61702d6e6f727468656173742d312e616d617a6f6e6177732e636f6d2f6366732d6c6f6f702d6669656c642d71756572792f73637265656e73686f742e706e67)

TIP
---

[](#tip)

- If you want to apply to some existing article, resave the article.
- This Plugin includes adding Time-Picker Field in CFS. (Using [CFS Time picker add-on](https://github.com/ersoma/cfs-time))
- Support Pages for `is_date()` includes `is_year()` `is_month()` `is_day()`.
- If you have set the 'FinishTime', it does not appear that post when it passes your set time. (Default: The Day Full)

Usage Example
-------------

[](#usage-example)

You can get a sub query with `new CFS_LFQ_Query()`

#### Example: Sub Query

[](#example-sub-query)

```
