Jump to content

Dplnum

From DynamicPageList3 Manual
Manual dplnum


This module tries to guess a number that is buried in text, using a set of heuristic rules which may work or not. The idea is to extract the number, so it can be used as a sorting value in the column of a DPL table output.

Syntax[edit]

{{#dplnum:text}} where text is a number within some text.

Examples[edit]

Example set The examples below are numbered for easier readability and comparison of their output.

1. {{#dplnum:this is 4711 a text with a number}}
2. {{#dplnum:well above 47 Mio. US$}}
3. {{#dplnum:13 Mrd}}
4. {{#dplnum:it is 47,123 Mio}}
5. {{#dplnum:it is 47.123,56}}
6. {{#dplnum:it is 47,000}}
7. {{#dplnum:it is 4.13}}
8. {{#dplnum:it is 4,13}}
9. {{#dplnum:it is 0,13}}

Result set: 1. 4711
2. 47000000
3. 13000000000
4. 47123000
5. 47123
6. 47
7. 413
8. 4
9. 0

Cookies help us deliver our services. By using our services, you agree to our use of cookies.