Skip to content

Commit 2a376ae

Browse files
authored
Merge branch 'ExpressionEngine:7.dev' into patch-18
2 parents 86e5cda + c5be66b commit 2a376ae

File tree

26 files changed

+979
-71
lines changed

26 files changed

+979
-71
lines changed

docs/add-ons/file.md

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -128,6 +128,37 @@ You can hard code the file entries tag to show specific files. You may also spec
128128

129129
If you want to display only the files that are in certain folder within an Upload Directory, specify the folder ID using this parameter.
130130

131+
### `file_type=`
132+
133+
file_type="img|doc"
134+
135+
Filter returned files by file type group, as classified by the core MIME groups (defined in the mimes configuration). You may specify one or more types; separate multiple values with the pipe character.
136+
137+
Or use "not" to exclude types:
138+
139+
file_type="not audio|video"
140+
141+
Common examples:
142+
143+
- Images only: `file_type="img"`
144+
- Documents only: `file_type="doc"`
145+
146+
147+
### `mime_type=`
148+
149+
mime_type="image/jpeg|image/png"
150+
151+
Filter returned files by MIME type. You may specify one or more MIME types; separate multiple values with the pipe character.
152+
153+
Or use "not" to exclude types:
154+
155+
mime_type="not video/mp4|video/quicktime"
156+
157+
Common examples:
158+
159+
- Images only: `mime_type="image/jpeg|image/png|image/gif"`
160+
- PDFs only: `mime_type="application/pdf"`
161+
131162
### `limit=`
132163

133164
limit="30"

docs/add-ons/pro-search/filters.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -235,7 +235,7 @@ You can use the native `search:field_name` parameter to target specific fields.
235235

236236
#### `search:field_name`
237237

238-
Like the [channel search:field_name= parameter](/channel/channel_entries.md#search-field-name).
238+
Like the [Channel search:field_name= parameter](/channel/entries.md#searchfield_name).
239239

240240
#### `search:field_name:column_name`
241241

docs/channels/channel-form/overview.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -265,10 +265,14 @@ If you have chosen [inline error handling](#error_handling), you can display the
265265

266266
Display a custom field's label.
267267

268+
You may also use `{label:title}` to display the label for the title field as defined in Channel settings.
269+
268270
### `{instructions:my_field_name}`
269271

270272
Display a custom field's instructions.
271273

274+
You may also use `{instructions:title}` to display the instructions for the title field as defined in Channel settings.
275+
272276
### `{selected_option:my_field_name}`
273277

274278
In an edit form, display the selected option for the specified custom field.

docs/channels/entries.md

Lines changed: 35 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -277,7 +277,7 @@ You can hard code the channel tag to show a specific channel entry. You may also
277277

278278
entry_id="13|42|147"
279279

280-
Or use "not" to exclude entries::
280+
Or use "not" to exclude entries:
281281

282282
entry_id="not 45|534|807"
283283

@@ -311,15 +311,15 @@ NOTE: **Note:** Using this parameter will automatically constrain the entries ta
311311

312312
### `group_id=`
313313

314-
NOTE: We recommend using [primary_role_id=](#primary_role_id) parameter instead, which works the same but more clearly conveys that the filtering is happening on primary role ID.
314+
NOTE: We recommend using the [primary_role_id=](#primary_role_id) parameter instead, which works the same but more clearly conveys that the filtering is happening on primary role ID.
315315

316316
group_id="4"
317317

318318
You can decide from which Member Role (by specifying the role ID) you wish entries to be shown. If you choose "4", then only entries created by members of the Primary Role with the ID of 4 will be shown. You can choose multiple Roles using a pipe:
319319

320320
group_id="2|3|4"
321321

322-
Or exclude role using "not"
322+
Or exclude roles using "not"
323323

324324
group_id="not 2|3|4"
325325

@@ -368,10 +368,14 @@ The `orderby` parameter sets the display order of the entries. Setting options f
368368
- `orderby="view_count_three"`
369369
- `orderby="view_count_four"`
370370

371-
In addition you can order by a [channel field](control-panel/field-manager/field-manager-settings.md). Use the "short_name" of the field:
371+
In addition, you can order by a [channel field](control-panel/field-manager/field-manager-settings.md). Use the "short_name" of the field:
372372

373373
orderby="name_of_field"
374374

375+
You can also order results by file names:
376+
377+
orderby="file_field:filename"
378+
375379
NOTE: **Note:** Ordering by a Relationship field will cause entries to appear in the order the relationships were made, not based on any content from the related entries.
376380

377381
NOTE: **Note:** **Random** ordered entries have special rules applied. "Sticky" entries will not appear first; they will appear randomly with all other entries. If the tag is not paginated, each page load, a new selection of random entries will be returned. If the tag **is** paginated, then the order of the entries is randomly set on the first page load and stored for the user's session so that entries show up only once in the paginated results.
@@ -398,17 +402,17 @@ Will result in:
398402

399403
Default Site - Entry One - Albert
400404
Default Site - Entry Two - Bobby
401-
Second Site  - Entry One - Alligator
402-
Second Site  - Entry Two - Buffalo
405+
Second Site - Entry One - Alligator
406+
Second Site - Entry Two - Buffalo
403407

404408
If you have multiple Sites where each site has a field with the same exact short name, then you can specify that short name (without the site specified) and ExpressionEngine will treat those two fields as the same value and be able to order them as if they were the same field:
405409

406410
orderby="body"
407411

408412
Default Site - Entry One - Albert
409-
Second Site  - Entry One - Alligator
413+
Second Site - Entry One - Alligator
410414
Default Site - Entry Two - Bobby
411-
Second Site  - Entry Two - Buffalo
415+
Second Site - Entry Two - Buffalo
412416

413417
Thus, the output will then be ordered by the body, regardless of the originating site.
414418

@@ -494,7 +498,10 @@ NOTE: **Note:** You will often use this parameter in conjunction with the [if no
494498

495499
The "search:" parameter allows you to constrain Channel Entries output based on content within your fields. You specify which field to search by using the field's short name immediately after "search:". You can search based on whether a field is an exact match to your provided term or whether or not a field simply contains your term.
496500

497-
NOTE: **Note:** Some fields store their content in a manner that affects the ability to work with this parameter. Grid fields, for instance, could only use this parameter for columns with "Include in search?" enabled. Relationship fields cannot be searched using the search parameter.
501+
NOTE: **Note:** Some fields store their content in a manner that affects the ability to work with this parameter. Grid fields, for instance, can only use this parameter for columns with "Include in search?" enabled (For performance, EE groups those columns into a searchable blob.). You can, however, search on Grid columns by using Pro Search's [`{exp:pro_search:results}`](add-ons/pro-search/tags.md#exppro_searchresults) tag and the [Field Search filter](/add-ons/pro-search/filters.md#field-search). Pro Search can also be used to filter entries by [title](/add-ons/pro-search/filters.md#searchtitle), [url_title](/add-ons/pro-search/filters.md#searchurltitle), [status](/add-ons/pro-search/filters.md#searchstatus), and [more](/add-ons/pro-search/filters.md#field-search). Relationship fields cannot be searched using the "search:" parameter.
502+
503+
504+
NOTE: **Note:** You can also use search:title and search:url_title in addition to searching field content. Remember that it is best to use url_title="something" if you're looking for an exact url_title match.
498505

499506
#### "Exact" Matching
500507

@@ -570,7 +577,7 @@ This example would return all results where the body field is empty.
570577

571578
search:body="not IS_EMPTY"
572579

573-
This example would return all results where the body field is **not** empty, i.e. only entries where the body field had content.
580+
This example would return all results where the body field is **not** empty, i.e., only entries where the body field had content.
574581

575582
The IS_EMPTY search constant can also be used in conjunction with other search terms, for both "Exact" and "Contains" type matching.
576583

@@ -590,13 +597,13 @@ NOTE: **Note:** You may use multiple search: parameters in a channel entries tag
590597

591598
{exp:channel:entries search:style="=ale" search:region="germany|belgium" search:rating="=3|4|5"}
592599

593-
When using multiple search parameters, all search parameters must be matched in order for an entry to be included. The above example would pull back only those entries where the style is 'ale', the region is 'germany' or 'belgium' and the rating is 1, 2 or 3.
600+
When using multiple search parameters, all search parameters must be matched in order for an entry to be included. The above example would pull back only those entries where the style is 'ale', the region is 'germany' or 'belgium', and the rating is 3, 4, or 5.
594601

595602
### `show_current_week=`
596603

597604
show_current_week="yes"
598605

599-
Requires use of the [display_by=](#display_by) "week" parameter. When set to "yes", it displays the current week by default (i.e. no pagination in the URL) and automatically adjusts the pagination links to indicate the correct page for that week.
606+
Requires use of the [display_by=](#display_by) "week" parameter. When set to "yes", it displays the current week by default (i.e., no pagination in the URL) and automatically adjusts the pagination links to indicate the correct page for that week.
600607

601608
### `show_expired=`
602609

@@ -739,15 +746,15 @@ This parameter limits the query by username. You can use the pipe character to q
739746

740747
username="tom|dick|harry"
741748

742-
Or you can add "not" to exclude usernames
749+
Or you can add "not" to exclude usernames:
743750

744751
username="not tom|dick|harry|fred"
745752

746753
You can also use the token `"CURRENT_USER"` to show entries from only the currently logged in user.
747754

748755
username="CURRENT_USER"
749756

750-
This allow each logged-in user to get only their entries. Users who are not logged in won't see anything. Alternatively, you can use the token `"NOT_CURRENT_USER"` to show entries **except** from the currently logged in user.
757+
This allows each logged-in user to get only their entries. Users who are not logged in won't see anything. Alternatively, you can use the token `"NOT_CURRENT_USER"` to show entries **except** from the currently logged-in user.
751758

752759
username="NOT_CURRENT_USER"
753760

@@ -791,7 +798,7 @@ If five entries are being displayed per page, then for the fourth entry on the s
791798

792799
### `{absolute_index}`
793800

794-
Similar to `absolute_count` but starts at 0 instead of 1. So the first entry will have value of "0" and the second entry will have a value of "1" etc.
801+
Similar to `absolute_count` but starts at 0 instead of 1. So the first entry will have a value of "0" and the second entry will have a value of "1", etc.
795802

796803
### `{absolute_results}`
797804

@@ -839,7 +846,7 @@ The name of the channel that the currently displayed entry is assigned to.
839846

840847
### `{channel_id}`
841848

842-
The ID number of the actual channel (not the _entry_.)
849+
The ID number of the actual channel (not the _entry_).
843850

844851
### `{channel_short_name}`
845852

@@ -969,7 +976,7 @@ The date on which the entry was last edited in GMT. This variable is **not** loc
969976

970977
### `{index}`
971978

972-
Similar to `count` but starts at 0 instead of 1. So the first entry will have value of "0" and the second entry will have a value of "1" etc.
979+
Similar to `count` but starts at 0 instead of 1. So the first entry will have a value of "0" and the second entry will have a value of "1", etc.
973980

974981
### `{ip_address}`
975982

@@ -985,13 +992,13 @@ This variable is replaced by a URL that passes the author's member name to your
985992

986993
### `{page_uri}`
987994

988-
If you have the Pages Module installed and if you have associated a static page with a channel entry (via the "Pages" section of the Publish tab), this is the page uri for the page. It will typically be used like so:
995+
If you have the Pages Module installed and if you have associated a static page with a channel entry (via the "Pages" section of the Publish tab), this is the page URI for the page. It will typically be used like so:
989996

990997
{if page_uri != ''} <a href="{page_uri}">View this page</a> {/if}
991998

992999
### `{page_url}`
9931000

994-
If you have the Pages Module installed and if you have associated a static page with a channel entry (via the "Pages" section of the Publish tab), this is the page url for the page (the site URL + the page URI). It will typically be used like so:
1001+
If you have the Pages Module installed and if you have associated a static page with a channel entry (via the "Pages" section of the Publish tab), this is the page URL for the page (the site URL + the page URI). It will typically be used like so:
9951002

9961003
{if page_url != ''} <a href="{page_url}">View this page</a> {/if}
9971004

@@ -1071,7 +1078,7 @@ The width of the signature image associated with the entry's author. Typically u
10711078

10721079
### `{status}`
10731080

1074-
The status of the entry (open, closed, etc.)
1081+
The status of the entry (open, closed, etc.).
10751082

10761083
### `{switch}`
10771084

@@ -1156,19 +1163,19 @@ Conditionals allow you to more precisely control your content.
11561163

11571164
NOTE: **Note:** A more complete explanation of conditional control structures and operators can be found on the [Conditional Tags](templates/conditionals.md) page.
11581165

1159-
Here is an example that tests for the "summary" field being not empty
1166+
Here is an example that tests for the "summary" field being not empty:
11601167

11611168
{if summary != ""}
11621169
The summary is not empty!
11631170
{/if}
11641171

1165-
An alternate, shorthand syntax can accomplish the same thing
1172+
An alternate, shorthand syntax can accomplish the same thing:
11661173

11671174
{if summary}
11681175
The summary is not empty!
11691176
{/if}
11701177

1171-
If only the variable name is in the conditional statement it tests for "not empty".
1178+
If only the variable name is in the conditional statement, it tests for "not empty".
11721179

11731180
Many of the single variables can be used in a conditional. You may always use the short name of one of your custom entry fields in a conditional. In addition, there are several unique conditionals.
11741181

@@ -1250,7 +1257,7 @@ Lastly, if you want to simply display your 404 page (with 404 headers) when no e
12501257

12511258
NOTE: **Note:** If you have several nested tags, each one would need to include a `{if no_results}` pair to be parsed correctly.
12521259

1253-
For instance, if you have Grid field with `{if no_results}` block, the parent `{exp:channel:entries}` tag pair would need to include `{if no_results}` block as well.
1260+
For instance, if you have a Grid field with an `{if no_results}` block, the parent `{exp:channel:entries}` tag pair would need to include an `{if no_results}` block as well:
12541261
```
12551262
{exp:channel:entries channel="blog"}
12561263
{if no_results} No entries {/if}
@@ -1297,13 +1304,13 @@ You may test whether an entry is set to be "sticky". You may also test whether i
12971304

12981305
[TOC=3]
12991306

1300-
Variable pairs contain an opening and closing tag as well as content in-between. Example:
1307+
Variable pairs contain an opening and closing tag as well as content in between. Example:
13011308

13021309
{date_heading} <h1>{entry_date format="%Y %m %d"}</h1> {/date_heading}
13031310

13041311
The reason variable pairs have an opening and closing pair is because the information between the pairs can be shown or not shown if the criteria for each tag is met.
13051312

1306-
In the case of the "date_heading" pair, for example, it only appears at a certain interval that you set (hourly, daily, weekly, monthly, etc.). By using a pair of variables you can put HTML formatting between them that only gets shown when the interval is met. Otherwise, the chunk is not displayed.
1313+
In the case of the "date_heading" pair, for example, it only appears at a certain interval that you set (hourly, daily, weekly, monthly, etc.). By using a pair of variables, you can put HTML formatting between them that only gets shown when the interval is met. Otherwise, the chunk is not displayed.
13071314

13081315
### `{date_footer}`
13091316

@@ -1462,9 +1469,9 @@ The category ID associated with the category's parent (or 0 in the case of a top
14621469

14631470
{path='channel/index'}
14641471

1465-
This variable will be replaced by a URL to the specifies Template Group/Template. The category designation information will automatically be added to the end of the URL so that the target page will know which category to display.
1472+
This variable will be replaced by a URL to the specified Template Group/Template. The category designation information will automatically be added to the end of the URL so that the target page will know which category to display.
14661473

1467-
If you want the category links to point to your site index instead of a particular template group/template you can use SITE_INDEX instead:
1474+
If you want the category links to point to your site index instead of a particular template group/template, you can use SITE_INDEX instead:
14681475

14691476
{categories} <a href="{path='SITE_INDEX'}">{category_name}</a> {/categories}
14701477

Lines changed: 67 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,67 @@
1+
# `channels:list`
2+
3+
Lists all channels in the system with their details in various formats.
4+
5+
TIP: If you would like to create or manage channels programmatically, see the Channel Model documentation.
6+
7+
## php eecli.php channels:list
8+
9+
### Options list:
10+
11+
```
12+
--site=<value>
13+
-s <value>
14+
Site ID to list channels for
15+
16+
--format=<value>
17+
-f <value>
18+
Output format: table, json, or csv
19+
20+
--channel_id=<value>
21+
-c <value>
22+
Filter by specific channel ID
23+
```
24+
25+
## Examples:
26+
27+
### Listing all channels:
28+
29+
The following commands will list all channels in table format (default):
30+
31+
`php eecli.php channels:list`
32+
33+
`php eecli.php channels:list --format=table`
34+
35+
`php eecli.php channels:list -f table`
36+
37+
### Listing channels for a specific site:
38+
39+
`php eecli.php channels:list --site=1`
40+
41+
`php eecli.php channels:list -s 1`
42+
43+
### Filtering by channel ID:
44+
45+
`php eecli.php channels:list --channel_id=5`
46+
47+
`php eecli.php channels:list -c 5`
48+
49+
### Output in JSON format:
50+
51+
`php eecli.php channels:list --format=json`
52+
53+
`php eecli.php channels:list -f json`
54+
55+
### Output in CSV format:
56+
57+
`php eecli.php channels:list --format=csv`
58+
59+
`php eecli.php channels:list -f csv`
60+
61+
### Combining filters:
62+
63+
You can combine multiple filters to narrow down your results:
64+
65+
`php eecli.php channels:list --site=1 --format=json`
66+
67+
`php eecli.php channels:list -s 1 -c 5 -f table`

0 commit comments

Comments
 (0)