Condition Types - Documentation topics on: conditions,condition types,rules,.

Condition Types

In the Conditions section of a Rule, you may select from a number of Condition Types to specify when a Rule will be executed (performing all the Rule Actions). This allows you to customize how your site displays based on the behavior and attributes of the front-end user.

Condition Descriptions

The table below lists and describes each of the condition types available. For more information on any of these conditions, please click the Condition name in the table to be taken to the appropriate place in the Parameters table, below.

Condition NameDescription
BrowserIdentifies the user's browser from the user agent in the request header, and compares it with the browser specified in the Condition.
Browser LanguageIdentifies the language the visitor has selected in their browser by inspecting the request header, and compares it with the lmaguage specified in the Condition.
Current URLCompares the current URL (the URL of the page on which the rule is being evaluated) with the URL specified in the Condition.
  • A Condition that tests only the folder path, instead of the full path to the index page will still evaluate to be true.
    • For example, if “/products/” is the URL specified in the Condition, and the visitor's current URL is “/products/index”, the condition would evaluate to “true”.
  • Parameters added to the end of the Current URL value will be ignored.
    • For example, the if the current URL is “/products/hdtv?id=12345”, it will be compared without the “?id=12345” (e.g. “/products/hdtv”).
Device TypeIdentifies the type of device being used by the visitor from the user agent in the request header, and compares it to the device type specified in the Condition.
Has Visited URLInspects a dotCMS maintained list of visited URLs in the current session to determine if a user has or has not visited a specific URL on your site during their current session.
Logged InEvaluates whether or not the user is currently logged in, and compares it to the login status specified in the Condition.
Number of Previous VisitsFinds the number of times the user has visited the site previously by inspecting site visitation “cookies” stored on the visitor's device, and compares it to the numeric value specified in the Condition.
Number of VisitsFinds the number of times the user has visited the site by inspecting site visitation “cookies” stored on the visitor's device, adds 1 (for the current visit), and compares the result to the numeric value specified in the Condition.
Note: This value includes the current visit, so it is equal to Number of Previous Visits + 1.
Pages ViewedInspects the dotCMS clickstream to count the number of pages viewed by the user in the current session, and compares it to the value specified in the Condition.
PersonaCompares the visitor's currently assigned Persona with the Persona specified in the Condition.
Referring URLFinds the Referring URL of the visitor from the request header, and compares it to URL specified in the Condition.
Request AttributeFinds the value of the specified attribute in the request header and compares it to the attribute value specified in the Condition.
Request HeaderFinds the specified value in the request header and compares it to the header value specified in the Condition.
Request ParameterFinds the specified parameter in the request and compares it to the parameter value specified in the Condition.
Selected LanguageIdentifies which dotCMS configured language (if any) a user has selected, and compares it with the language specified in the Condition.
Session AttributeFinds the value of the specified attribute in the current session and compares it to the attribute value specified in the Condition.
Visitor Operating SystemIdentifies the user's operating system from the user agent in the request header, and compares it with the operating system specified in the Condition.
Visitor's CountryUses GeoIP2 services to identify the visitor's country based on the visitor's IP address, and compares it to the country specified in the Condition.
Visitor's Date-TimeUses GeoIP2 services to identify the visitor's date and time based on the visitor's IP address, and compares it to the date and time specified in the Condition.
Visitor's LocationUses GeoIP2 services to approximate the visitor's geolocation based on the visitor's IP address, and compares the visitor's geographical distance from the target geolocation with the distance specified in the Condition.

Note:

  • This product includes GeoLite2 data created by MaxMind, available from http://www.maxmind.com.
  • The version of the MaxMind GeoIP database that ships with dotCMS is the GeoLite2 free version, which has limited location resolution and is licensed for development purposes only.
    • The GeoIP libraries that ship with dotCMS may be easily upgraded to a more accurate GeoIP database.
    • If you wish to use the MaxMind GeoLite2 database for your production site, or if you wish to perform more accurate geolocation of users based on the user's IP address, you must contact MaxMind and meet all MaxMind requirements for registration or purchase of an appropriate license.

Condition Parameters

The following table displays the required parameters and accepted comparisons for each of the condition types, and the FORMAT: value that can be analyzed for each condition.

Condition Name Parameters Comparison Type Format or Value
Browser None Is,
Is not
Selection Selections: IE, Edge, Safari, Firefox, Chrome, Opera
Browser Language None Is,
Is not
Selection Selections: Afar, Abkhazian, Avestan, Afrikaans, Akan, Amharic, Aragonese, Arabic, Assamese, Avaric, Aymara, Azerbaijani, Bashkir, Belarusian, Bulgarian, Bihari languages, Bislama, Bambara, Tibetan, Breton, Bosnian, Catalan, Chechen, Chamarro, Corsican, Cree, Czech, Church Slavic; Old Slavonic; Church Slavonic; Old Bulgarian; Old Church Slavonic, Chuvash, Welsh, Danish, German, Divehi; Dhivehi; Maldivian, Dzongkha, Ewe, Greek; Modern (1453-), English, Esperantos, Spanish; Castilian, Estonian, Basque, Persian, Fulah, Finnish, Fijian, Faroese, French, Western Frisian, Irish, Gaelic; Scottish Gaelic, Galician, Guarani, Gujarati, Manx, Hausa, Hebrew, Hindi, Hiri Moto, Croation, Haitian; Haitian Creole, Hungarian, Armenian, Herero, Interlingua (International Auxiliary Language Association), Indonesian, Interlingue; Occidental, Igbo, Sichuan Yi; Nuosu, Inupiaq, Ido, Icelandic, Italian, Inuktitut, Japanese, Javanese, Georgian, Kongo, Kikuya; Gikuyu, Kuanyama; Kwanyama, Kazakh, Kalaallisut; Greenlandic, Central Khmer, Kannada, Korean, Kanuri, Kashmiri, Kurdich, Komi, Cornish, Kirghiz; Kyrgyz, Latin, Luxembourgish; Letzeburgesch, Ganda, Limburgan; Limburger; Limburgish, Lingala, Lao, Lithuanian, Luba-Katanga, Latvian, Malagasy, Marshallese, Maori, Macedonian, Malayalam, Mongolian, Marathi, Malay, Maltese, Burmese, Nauru, Bokmål; Norwegian; Norgegian Bokmål, Ndebele North; North Ndebele, Nepali, Ndonga, Dutch; Flemish, Norwegian Nynorsk; Nynorsk Norwegian, Norwegian, Ndebele South; South Ndebele, Navajo; Navaho, Chichewa; Chewa; Nyanja, Occitan (post 1500), Ojibwa, Oriya, Ossetian; Ossetic, Panjabi; Punjabi, Pali, Polish, Pushto; Pashto, Portuguese, Quechua, Romansh, Rundi, Romanian; Moldavian; Moldovan, Russian, Kinyarwanda, Sanskrit, Sardinian, Sindhi, Northern Sami, Sango, Sinhala; Sinhalese, Slovak, Slovenian, Samoan, Shona, Somali, Albanian, Serbian, Swati, Sotho Southern, Sudanese, Swedish, Swahili, Tamil, Telugu, Tajik, Thai, Tigrinya, Turkmen, Tagalog, Tswana, Tonga (Tonga Islands), Turkish, Tsonga, Tatar, Twi, Tahitian, Uighur; Uyghur, Ukranian, Urdu, Uzbek, Venda, Vietnamese, Volapük, Walloon, Wolof, Xhosa, Yiddish, Yoruba, Zhuang; Chuang, Chinese, Zulu
Current URL None Is,
Is not,
Starts with,
Ends with,
Contains,
regex
Text URL
Please Note: For the "Is", "Is Not", and "Ends With" comparisons, URL values ending in a / will automatically reference the CMS_INDEX_PAGE property for the folder.
For example, somefolder/ will be treated as somefolder/{CMS_INDEX_PAGE}.
References to folders without the trailing / will not automatically reference the CMS_INDEX_PAGE page property.
Device Type None Is,
Is not
Selection Selections: Computer, Mobile, Tablet, Wearable computer, Digital media receiver, Game console
Has Visited URL None Is not,
Starts with,
Ends with,
Contains,
Regex
Text URL
Logged In None Is,
Is not
None N/A
Number of Previous Visits None Is equal to,
Is less than,
Is greater than,
Is less than or equal to,
Is greater than or equal to
Integer Number of previous visits (not including the current visit)
Number of Visits None Is equal to,
Is less than,
Is greater than,
Is less than or equal to,
Is greater than or equal to
Integer Number of visits (including the current visit)
Pages Viewed None Is equal to,
Is not equal to,
Is less than,
Is greater than,
Is less than or equal to,
Is greater than or equal to
Integer Number of pages
Persona None Is,
Is not
Selection Select a Persona from the list of Personas defined on the system.
Referring URL None Is,
Is not,
Exists,
Starts with,
Ends with,
Contains,
Regex
Text URL
Request Attribute Attribute Name Is,
Is not,
Exists,
Starts with,
Ends with,
Contains,
Regex
Text Attribute Value
Request Header Header Name:
Accept,
Accept‑Charset,
Accept‑Datetime,
Accept‑Encoding,
Accept‑Language,
Authorization,
Cache‑Control,
Connection,
Content‑Length,
Content‑MD5,
Content‑Type,
Cookie,
Date,
DNT,
Expect,
From,
Front‑End‑Https,
Host,
If‑Match,
If‑Modified‑Since,
If‑None‑Match,
If‑Range,
If‑Unmodified‑Since,
Max‑Forwards,
Origin,
Pragma,
Proxy‑Authorization,
Proxy‑Connection,
Range,
Referer,
TE,
Upgrade,
User‑Agent,
Via,
Warning,
X‑Requested‑With,
X‑Forwaded‑For,
X‑Forwaded‑Host,
X‑Http‑Method‑Override,
X‑ATT‑DeviceId,
X‑Wap‑Profile,
X‑UIDH,
X‑Csrf‑Token
OR Enter any value
Is,
Is not,
Exists,
Starts with,
Ends with,
Contains,
Regex
Text Header Value
Request Parameter Parameter Name Is,
Is not,
Exists,
Starts with,
Ends with,
Contains,
Regex
Text Parameter Value
Selected Language None Is,
Is not
Selection Select from a list of languages configured in dotCMS
Session Attribute Attribute Name Is,
Is not,
Exists,
Starts with,
Ends with,
Contains,
Regex
Text Attribute Value
Visitor Operating System None Is,
Is not
Selection Select from a list of Operating System values supported by the User Agent Viewtool
Visitor's Country None Is,
Is not
Selection Selections: Afghanistan, Albania, Algeria, Andorra, Angola, Anguilla, Antigua and Barbuda, Argentina, Armenia, Australia, Austria, Azerbaijan, Bahamas, Bahrain, Bangladesh, Barbados, Belarus, Belgium, Belize, Benin, Bhutan, Bolivia, Bosnia and Herzegovina, Botswana, Brazil, Brunei, Bulgaria, Burkina Faso, Burundi, Cabo Verde, Cambodia, Cameroon, Canada, Central African Republic, Chad, Chile, China, Colombia, Comoros, Congo Republic of the, Congo Democratic Republic of the, Costa Rica, Cote d'Ivoire, Croatia, Cuba, Cyprus, Czech Republic, Denmark, Djibouti, Dominica, Dominican Republic, Ecuador, Egypt, El Salvador, Equatorial Guinea, Eritrea, Estonia, Ethiopia, Fiji, Finland, France, Gabon, Gambia, Georgia, Germany, Ghana, Greece, Grenada, Guatemala, Guinea, Guinea-Bissau, Guyana, Haiti, Honduras, Hungary, Iceland, India, Indonesia, Iran, Iraq, Ireland, Israel, Italy, Jamaica, Japan, Jordan, Kazakhstan, Kenya, Kiribati, Kosovo, Kuwait, Kyrgyzstan, Laos, Latvia, Lebanon, Lesotho, Liberia, Libya, Liechtenstein, Lithuania, Luxembourg, Macedonia, Madagascar, Malawi, Malaysia, Maldives, Mali, Malta, Marshall Islands, Mauritania, Mauritius, Mexico, Micronesia, Moldova, Monaco, Mongolia, Montenegro, Morocco, Mozambique, Myanmar (Burma), Namibia, Nauru, Nepal, Netherlands, New Zealand, Nicaragua, Niger, Nigeria, North Korea, Norway, Oman, Pakistan, Palau, Palestine, Panama, Papua New Guinea, Paraguay, Peru, Philippines, Poland, Portugal, Qatar, Romania, Russia, Rwanda, St. Kitts and Nevis, St. Lucia, St. Vincent and The Grenadines, Samoa, San Marino, Sao Tome and Principe, Saudi Arabia, Senegal, Serbia, Seychelles, Sierra Leone, Singapore, Slovakia, Slovenia, Solomon Islands, Somalia, South Africa, South Korea, South Sudan, Spain, Sri Lanka, Sudan, Suriname, Swaziland, Sweden, Switzerland, Syria, Taiwan, Tajikistan, Tanzania, Thailand, Timor-Leste, Togo, Tonga, Trinidad and Tobago, Tunisia, Turkey, Turkmenistan, Tuvalu, Uganda, Ukraine, United Arab Emirates, UK (United Kingdom), USA (United States of America), Uruguay, Uzbekistan, Vanuatu, Vatican City (Holy See), Venezuela, Vietnam, Yemen, Zambia, Zimbabwe
Enter any value
Visitor's Date-Time None Is between,
Is greater than,
Is less than
Date and Time Enter the Date & Time or Select from the Calendar
Visitor's Location Redius in miles/kilometers Within, Not Within Location Set the location using the visual map