Title: Conditional based validation
Last modified: August 30, 2024

---

# Conditional based validation

 *  Resolved [divyeshpanchal](https://wordpress.org/support/users/divyeshpanchal/)
 * (@divyeshpanchal)
 * [1 year, 9 months ago](https://wordpress.org/support/topic/conditional-based-validation/)
 * After adding a product to the cart, go to the checkout page where I want to apply
   conditional validation. If the user selects “Order type: Company,” two other 
   fields should be required; otherwise, those fields should not be required.
 * [Screenshot](https://i.postimg.cc/1tWTMzY3/Screenshot-from-2024-08-30-09-51-33.png)
 * ![](https://wordpress.org/7bf09be5-a693-49df-9fe9-02dda6f94cda)
    -  This topic was modified 1 year, 9 months ago by [divyeshpanchal](https://wordpress.org/support/users/divyeshpanchal/).
 * The page I need help with: _[[log in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fwordpress.org%2Fsupport%2Ftopic%2Fconditional-based-validation%2F%3Foutput_format%3Dmd&locale=en_US)
   to see the link]_

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

 *  Plugin Author [SilkyPress](https://wordpress.org/support/users/diana_burduja/)
 * (@diana_burduja)
 * [1 year, 9 months ago](https://wordpress.org/support/topic/conditional-based-validation/#post-17984547)
 * Hello [@divyeshpanchal](https://wordpress.org/support/users/divyeshpanchal/),
 * unfortunately, the Input Field Block plugin doesn’t support conditional validation.
   We’re planning to add the feature sometime in the future.
 *  Thread Starter [divyeshpanchal](https://wordpress.org/support/users/divyeshpanchal/)
 * (@divyeshpanchal)
 * [1 year, 9 months ago](https://wordpress.org/support/topic/conditional-based-validation/#post-17984660)
 * Hello, could you please provide a detailed answer to my question on how to add
   fields based on specific conditions?
 *  Plugin Author [SilkyPress](https://wordpress.org/support/users/diana_burduja/)
 * (@diana_burduja)
 * [1 year, 9 months ago](https://wordpress.org/support/topic/conditional-based-validation/#post-17984667)
 * Hello, it is not possible to add fields based on specific conditions. The plugin
   doesn’t support the feature.
 *  [James](https://wordpress.org/support/users/james-feaver/)
 * (@james-feaver)
 * [1 year, 8 months ago](https://wordpress.org/support/topic/conditional-based-validation/#post-18035330)
 * Hello,
 * I read your reply to the original poster: _“it is not possible to add fields 
   based on specific conditions. “_. That’s a shame. At a first quick look your 
   plugin is brilliant. It makes the complicated job of adding custom fields to 
   a block-based checkout VERY easy compared to WooCommerce’s VERY technical route
   with json, Webpack and JavaScript. However, I am looking to replace a plugin 
   I wrote for the classic checkout that uses conditions (if a specific product 
   is in the cart) to determine display of certain custom fields.
 * Hoping that gets on to your development map.
 * Thanks,
 * James

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

The topic ‘Conditional based validation’ is closed to new replies.

 * ![](https://ps.w.org/silkypress-input-field-block/assets/icon.svg?rev=3034999)
 * [SilkyPress Input Field Block](https://wordpress.org/plugins/silkypress-input-field-block/)
 * [Support Threads](https://wordpress.org/support/plugin/silkypress-input-field-block/)
 * [Active Topics](https://wordpress.org/support/plugin/silkypress-input-field-block/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/silkypress-input-field-block/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/silkypress-input-field-block/reviews/)

 * 6 replies
 * 3 participants
 * Last reply from: [James](https://wordpress.org/support/users/james-feaver/)
 * Last activity: [1 year, 8 months ago](https://wordpress.org/support/topic/conditional-based-validation/#post-18035330)
 * Status: resolved