Skip to content

Commit

Permalink
Add example for numRows (#770)
Browse files Browse the repository at this point in the history
  • Loading branch information
kitzberger authored Aug 2, 2023
1 parent a89d347 commit 3543204
Showing 1 changed file with 21 additions and 0 deletions.
21 changes: 21 additions & 0 deletions Documentation/Functions/Numrows.rst
Original file line number Diff line number Diff line change
Expand Up @@ -45,3 +45,24 @@ select

The sub-property :typoscript:`selectFields` is overridden internally with
:php:`count(*)`.

.. _numRows-examples:

Example
=======

Get the number of content elements within certain colPos of the current page.

.. code-block:: typoscript
:caption: EXT:site_package/Configuration/TypoScript/setup.typoscript
10 = FLUIDTEMPLATE
10 {
variables {
numberOfContentElementsInColPosOne = TEXT
numberOfContentElementsInColPosOne.numRows {
table = tt_content
select.where = {#colPos}=1
}
}
}

0 comments on commit 3543204

Please sign in to comment.