Title: &#8220;And&#8221; &#8220;OR&#8221; statement
Last modified: February 17, 2017

---

# “And” “OR” statement

 *  Resolved [siltygravel](https://wordpress.org/support/users/siltygravel/)
 * (@siltygravel)
 * [9 years, 2 months ago](https://wordpress.org/support/topic/and-or-statement/)
 * Hi,
 * Would you please add “AND” “OR” statement to your code.
 * Cheers,
    MUNIF

Viewing 7 replies - 1 through 7 (of 7 total)

 *  Plugin Author [Jules Colle](https://wordpress.org/support/users/jules-colle/)
 * (@jules-colle)
 * [9 years, 2 months ago](https://wordpress.org/support/topic/and-or-statement/#post-8815557)
 * I might, but in fact you can already achieve AND/OR logic with the tools provided.
 * Here’s an example:
 * OR
    —
 * form:
 *     ```
       [text text-1]
       [text text-2]
   
       [group group-1]
       This wil show if either text-1 OR text-2 equals "true"
       [/group]
       ```
   
 * conditions:
 *     ```
       if [text-1] equals "true" then show [group-1]
       if [text-2] equals "true" then show [group-1]
       ```
   
 * AND (a little more complex, but can be done like this:
    —
 * form:
 *     ```
       [text text-1]
       [text text-2]
   
       [group group-1][group group-1-1]
       This wil show if text-1 AND text-2 both equal "true"
       [/group][/group]
       ```
   
 * conditions:
 *     ```
       if [text-1] equals "true" then show [group-1]
       if [text-2] equals "true" then show [group-1-1]
       ```
   
    -  This reply was modified 9 years, 2 months ago by [Jules Colle](https://wordpress.org/support/users/jules-colle/).
 *  Thread Starter [siltygravel](https://wordpress.org/support/users/siltygravel/)
 * (@siltygravel)
 * [9 years, 2 months ago](https://wordpress.org/support/topic/and-or-statement/#post-8815611)
 * Thanks,
    I’ll try…
 *  Plugin Author [Jules Colle](https://wordpress.org/support/users/jules-colle/)
 * (@jules-colle)
 * [9 years, 2 months ago](https://wordpress.org/support/topic/and-or-statement/#post-8818762)
 * any luck?
 *  Thread Starter [siltygravel](https://wordpress.org/support/users/siltygravel/)
 * (@siltygravel)
 * [9 years, 2 months ago](https://wordpress.org/support/topic/and-or-statement/#post-8819153)
 * It works, but my condition list is very long now.
 *  Plugin Author [Jules Colle](https://wordpress.org/support/users/jules-colle/)
 * (@jules-colle)
 * [9 years, 2 months ago](https://wordpress.org/support/topic/and-or-statement/#post-8821012)
 * Could you post you form and conditions here so I can see if there’s a more efficient
   way to organize them?
 *  Thread Starter [siltygravel](https://wordpress.org/support/users/siltygravel/)
 * (@siltygravel)
 * [9 years, 2 months ago](https://wordpress.org/support/topic/and-or-statement/#post-8847883)
 * <span style=”color: #ff9900;”><b> Name
    [text* Name id:Name placeholder “Name”]
   </label>
 * <span style=”color: #ff9900;”><b> Surname
    [text* Surname id:Surname placeholder“
   Surname”]</label>
 * <span style=”color: #ff9900;”><b> Your Email
    [email* your-email id:your-email
   placeholder “youremail@example.com”]</label>
 * <label><span style=”color: #ff9900;”> Your Phone No
    [tel* YourPhoneNo placeholder“
   +Country Code (Area Code) Phone Number”]</label>
 * <span style=”color: #ff9900;”><b> Journey <span style=”color: #000000;”>
    [radio
   Journey id:Journey use_label_element default:1 “One way” “Round Trip”]</label
   >
 * <span style=”color: #ff9900;”><b> From
    [select* From id:From class:1 “ANTALYA
   AIRPORT” “ANTALYA CITY CENTER” “ALANYA” “AVSALLAR” “BELDIBI” “BELEK” “BODRUM”“
   CAMYUVA” “CIRALI” “DALAMAN” “FETHIYE” “GOCEK” “GOYNUK” “KALKAN” “KAS” “KEMER”“
   KIRIS” “KIZILAGAC” “KIZILOT” “KONAKLI” “KUNDU” “LARA” “MANAVGAT” “MARMARIS” “
   OLUDENIZ” “OLYMPOS” “PORT AKDENIZ (AIDA)” “SIDE” “TEKIROVA”] </label>
 * <span style=”color: #ff9900;”><b> To
    [select* To id:To class:1 “ANTALYA AIRPORT”“
   ANTALYA CITY CENTER” “ALANYA” “AVSALLAR” “BELDIBI” “BELEK” “BODRUM” “CAMYUVA”“
   CIRALI” “DALAMAN” “FETHIYE” “GOCEK” “GOYNUK” “KALKAN” “KAS” “KEMER” “KIRIS” “
   KIZILAGAC” “KIZILOT” “KONAKLI” “KUNDU” “LARA” “MANAVGAT” “MARMARIS” “OLUDENIZ”“
   OLYMPOS” “PORT AKDENIZ (AIDA)” “SIDE” “TEKIROVA”] </label>
 * <span style=”color: #ff9900;”><b> Arrival Date
    [date* ArrivalDate min:today 
   id:ArrivalDate]<label>
 * <span style=”color: #ff9900;”><b> Arrival Flight No
    [text* FlightNo1 id:FlightNo1
   class:1 placeholder “Your Flight No i.e. TK1234, LH1784, XQ789″]</label>
 * <span style=”color: #ff9900;”><b> Arrival Time
    [text* Time1 id:Time1 class:time
   placeholder “Your Flight Arrival Time 13:45 or 1:45 PM”]</label>
 * <span style=”color: #ff9900;”><b> Hotel Name
    [text* Hotel Name id:Hotel placeholder“
   Hotel Name”]</label>
 * [group DepartureDate]
    <span style=”color: #ff9900;”><b> Departure [date* DepartureDate
   min:today id:DepartureDate]
 * <span style=”color: #ff9900;”><b> Departure Flight No
    [text* FlightNo2 id:FlightNo2
   class:1 placeholder “Your Flight No i.e. TK1234, LH1784, XQ789″]
 * <span style=”color: #ff9900;”><b> Departure Time
    [text* Time2 id:Time2 class:
   time placeholder “Your Flight Departure Time 13:45 or 1:45 PM”]</label> [/group]
 * <span style=”color: #ff9900;”><b> Vehicle Type?
    [select* VehicleType id:VehicleType
   include_blank “ECONOMY / SEDAN (MAX 4 PAX)” “FAMILY / CARAVELLE (MAX 9 PAX)” “
   GROUP / MIDIBUS (MAX 13 PAX)” “VIP / MERCEDES VITO (MAX 6 PAX)”]</label>
 * [group PAX_SEDAN1]
 * 
    [group S] [group ONE-WAY] [group AYT-S] [group S-EURO20] <b><span style=”color:#
   0085ff;font-size:35px”>Total Cost : <b><span style=”color: #ff0000;font-size:
   60px”>€20 [/group] [group S-EURO25] <b><span style=”color: #0085ff;font-size:
   35px”>Total Cost : <b><span style=”color: #ff0000;font-size:60px”>€25 [/group][
   group S-EURO30] <b><span style=”color: #0085ff;font-size:35px”>Total Cost : <
   b><span style=”color: #ff0000;font-size:60px”>€30 [/group] [group S-EURO35] <
   b><span style=”color: #0085ff;font-size:35px”>Total Cost : <b><span style=”color:#
   ff0000;font-size:60px”>€35 [/group] [group S-EURO40] <b><span style=”color: #
   0085ff;font-size:35px”>Total Cost : <b><span style=”color: #ff0000;font-size:
   60px”>€40 [/group] [group S-EURO45] <b><span style=”color: #0085ff;font-size:
   35px”>Total Cost : <b><span style=”color: #ff0000;font-size:60px”>€45 [/group][
   group S-EURO50] <b><span style=”color: #0085ff;font-size:35px”>Total Cost : <
   b><span style=”color: #ff0000;font-size:60px”>€50 [/group] [group S-EURO85] <
   b><span style=”color: #0085ff;font-size:35px”>Total Cost : <b><span style=”color:#
   ff0000;font-size:60px”>€85 [/group] [group S-EURO90] <b><span style=”color: #
   0085ff;font-size:35px”>Total Cost : <b><span style=”color: #ff0000;font-size:
   60px”>€90 [/group] [group S-EURO100] <b><span style=”color: #0085ff;font-size:
   35px”>Total Cost : <b><span style=”color: #ff0000;font-size:60px”>€100 [/group][
   group S-EURO125] <b><span style=”color: #0085ff;font-size:35px”>Total Cost : 
   <b><span style=”color: #ff0000;font-size:60px”>€125 [/group] [group S-EURO160]
   <b><span style=”color: #0085ff;font-size:35px”>Total Cost : <b><span style=”color:#
   ff0000;font-size:60px”>€160 [/group][/group][/group]
 * [group SR]
    [group ROUND-TRIP] [group AYT-SR] [group S-EURO20R] <b><span style
   =”color: #0085ff;font-size:35px”>Total Cost : <b><span style=”color: #ff0000;
   font-size:60px”>€40 [/group] [group S-EURO25R] <b><span style=”color: #0085ff;
   font-size:35px”>Total Cost : <b><span style=”color: #ff0000;font-size:60px”>€
   50 [/group] [group S-EURO30R] <b><span style=”color: #0085ff;font-size:35px”>
   Total Cost : <b><span style=”color: #ff0000;font-size:60px”>€60 [/group] [group
   S-EURO35R] <b><span style=”color: #0085ff;font-size:35px”>Total Cost : <b><span
   style=”color: #ff0000;font-size:60px”>€70 [/group] [group S-EURO40R] <b><span
   style=”color: #0085ff;font-size:35px”>Total Cost : <b><span style=”color: #ff0000;
   font-size:60px”>€80 [/group] [group S-EURO45R] <b><span style=”color: #0085ff;
   font-size:35px”>Total Cost : <b><span style=”color: #ff0000;font-size:60px”>€
   90 [/group] [group S-EURO50R] <b><span style=”color: #0085ff;font-size:35px”>
   Total Cost : <b><span style=”color: #ff0000;font-size:60px”>€100 [/group] [group
   S-EURO85R] <b><span style=”color: #0085ff;font-size:35px”>Total Cost : <b><span
   style=”color: #ff0000;font-size:60px”>€170 [/group] [group S-EURO90R] <b><span
   style=”color: #0085ff;font-size:35px”>Total Cost : <b><span style=”color: #ff0000;
   font-size:60px”>€180 [/group] [group S-EURO100R] <b><span style=”color: #0085ff;
   font-size:35px”>Total Cost : <b><span style=”color: #ff0000;font-size:60px”>€
   200 [/group] [group S-EURO125R] <b><span style=”color: #0085ff;font-size:35px”
   >Total Cost : <b><span style=”color: #ff0000;font-size:60px”>€250 [/group] [group
   S-EURO160R] <b><span style=”color: #0085ff;font-size:35px”>Total Cost : <b><span
   style=”color: #ff0000;font-size:60px”>€320 [/group][/group][/group]
 * <b><span style=”color: #FF9900;font-size:25px”>No’s of Passengers?  [select* 
   PAX_SEDAN id:PAX_SEDAN include_blank “1” “2” “3” “4”]
    [/group]
 * —————————————
    CONDITIONAL FORMAT
 * if [To] equals “LARA” then show [C-EURO45]
    if [From] equals “ANTALYA AIRPORT”
   then show [AYT-C] if [VehicleType] equals “FAMILY / CARAVELLE (MAX 9 PAX)” then
   show [C] if [To] equals “BODRUM” then show [S-EURO160R] if [To] equals “MARMARIS”
   then show [S-EURO125R] if [To] equals “GOCEK” then show [S-EURO100R] if [To] 
   equals “DALAMAN” then show [S-EURO100R] if [To] equals “FETHIYE” then show [S-
   EURO90R] if [To] equals “OLUDENIZ” then show [S-EURO90R] if [To] equals “KAS”
   then show [S-EURO85R] if [To] equals “KALKAN” then show [S-EURO85R] if [To] equals“
   OLYMPOS” then show [S-EURO50R] if [To] equals “CIRALI” then show [S-EURO50R] 
   if [To] equals “TEKIROVA” then show [S-EURO45R] if [To] equals “CAMYUVA” then
   show [S-EURO45R] if [To] equals “ALANYA” then show [S-EURO45R] if [To] equals“
   KONAKLI” then show [S-EURO45R] if [To] equals “AVSALLAR” then show [S-EURO45R]
   if [To] equals “KIRIS” then show [S-EURO40R] if [To] equals “KEMER” then show[
   S-EURO35R] if [To] equals “KIZILOT” then show [S-EURO35R] if [To] equals “KIZILAGAC”
   then show [S-EURO35R] if [To] equals “MANAVGAT” then show [S-EURO35R] if [To]
   equals “SIDE” then show [S-EURO35R] if [To] equals “GOYNUK” then show [S-EURO30R]
   if [To] equals “BELDIBI” then show [S-EURO30R] if [To] equals “BELEK” then show[
   S-EURO25R] if [To] equals “PORT AKDENIZ (AIDA)” then show [S-EURO20R] if [To]
   equals “LARA” then show [S-EURO20R] if [To] equals “KUNDU” then show [S-EURO20R]
   if [To] equals “ANTALYA CITY CENTER” then show [S-EURO20R] if [From] equals “
   ANTALYA AIRPORT” then show [AYT-SR] if [Journey] equals “Round Trip” then show[
   ROUND-TRIP] if [VehicleType] equals “ECONOMY / SEDAN (MAX 4 PAX)” then show [
   SR] if [To] equals “BODRUM” then show [S-EURO160] if [To] equals “MARMARIS” then
   show [S-EURO125] if [To] equals “GOCEK” then show [S-EURO100] if [To] equals “
   DALAMAN” then show [S-EURO100] if [To] equals “FETHIYE” then show [S-EURO90] 
   if [To] equals “OLUDENIZ” then show [S-EURO90] if [To] equals “KAS” then show[
   S-EURO85] if [To] equals “KALKAN” then show [S-EURO85] if [To] equals “OLYMPOS”
   then show [S-EURO50] if [To] equals “CIRALI” then show [S-EURO50] if [To] equals“
   TEKIROVA” then show [S-EURO45] if [To] equals “CAMYUVA” then show [S-EURO45] 
   if [To] equals “ALANYA” then show [S-EURO45] if [To] equals “KONAKLI” then show[
   S-EURO45] if [To] equals “AVSALLAR” then show [S-EURO45] if [To] equals “KIRIS”
   then show [S-EURO40] if [To] equals “KEMER” then show [S-EURO35] if [To] equals“
   KIZILOT” then show [S-EURO35] if [To] equals “KIZILAGAC” then show [S-EURO35]
   if [To] equals “MANAVGAT” then show [S-EURO35] if [To] equals “SIDE” then show[
   S-EURO35] if [To] equals “GOYNUK” then show [S-EURO30] if [To] equals “BELDIBI”
   then show [S-EURO30] if [To] equals “BELEK” then show [S-EURO25] if [To] equals“
   PORT AKDENIZ (AIDA)” then show [S-EURO20] if [To] equals “LARA” then show [S-
   EURO20] if [To] equals “KUNDU” then show [S-EURO20] if [To] equals “ANTALYA CITY
   CENTER” then show [S-EURO20] if [From] equals “ANTALYA AIRPORT” then show [AYT-
   S] if [Journey] equals “One way” then show [ONE-WAY] if [VehicleType] equals “
   ECONOMY / SEDAN (MAX 4 PAX)” then show [S] if [VehicleType] equals “VIP / MERCEDES
   VITO (MAX 6 PAX)” then show [PAX_VITO_VIP1] if [VehicleType] equals “GROUP / 
   MIDIBUS (MAX 13 PAX)” then show [PAX_MIDIBUS1] if [VehicleType] equals “FAMILY/
   CARAVELLE (MAX 9 PAX)” then show [PAX_CARAVELLE1] if [VehicleType] equals “ECONOMY/
   SEDAN (MAX 4 PAX)” then show [PAX_SEDAN1] if [Journey] equals “Round Trip” then
   show [DepartureDate] if [Baby_Yes_No] equals “Yes” then show [Baby]
 *  Plugin Author [Jules Colle](https://wordpress.org/support/users/jules-colle/)
 * (@jules-colle)
 * [9 years, 2 months ago](https://wordpress.org/support/topic/and-or-statement/#post-8850882)
 * Whoa! that is a big form 🙂 Thanks for convincing me of the usefulness of AND/
   OR conditions.

Viewing 7 replies - 1 through 7 (of 7 total)

The topic ‘“And” “OR” statement’ is closed to new replies.

 * ![](https://ps.w.org/cf7-conditional-fields/assets/icon-256x256.png?rev=2072595)
 * [Conditional Fields for Contact Form 7](https://wordpress.org/plugins/cf7-conditional-fields/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/cf7-conditional-fields/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/cf7-conditional-fields/)
 * [Active Topics](https://wordpress.org/support/plugin/cf7-conditional-fields/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/cf7-conditional-fields/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/cf7-conditional-fields/reviews/)

 * 7 replies
 * 2 participants
 * Last reply from: [Jules Colle](https://wordpress.org/support/users/jules-colle/)
 * Last activity: [9 years, 2 months ago](https://wordpress.org/support/topic/and-or-statement/#post-8850882)
 * Status: resolved