• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar

Payments Plugin for Stripe

Stripe payment plugins for your WordPress site

  • Home
  • Documentation
  • Addons
  • Login
    • Sign In
    • Edit Profile
    • Terms & Conditions
    • My Downloads
    • License Key
  • Support
    • Support Forum
    • Forum Search
    • Forum Login
    • Forum Registration
    • Email Support for Customers
  • Contact Us
  • Show Search
Hide Search
You are here: Home / Topics / Custom field validation

[Resolved] Custom field validation

· ·

Home › Forums › Stripe Payments Plugin › Custom field validation

Tagged: Custom Fields

  • This topic has 2 replies, 2 voices, and was last updated 1 year, 7 months ago by facet5.
Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • August 5, 2021 at 4:31 pm #4153
    facet5
    Participant

    Hi,

    We need to add some validation to custom fields – check that two email fields match before allowing a purchase to go ahead.

    I have tried adding <script> tags to the description which should accept html according to documentation but these are being rendered as text – possibly for security reasons.

    Custom validation should be possible according to this post:
    https://s-plugins.com/forums/topic/validate-custom-fields/

    Can you let us know how to achieve this please?
    I am comfortable with javascript, regex etc. and could probably edit php if necessary.

    Thanks,

    Nathan

    August 6, 2021 at 10:17 am #4154
    alexanderfoxc
    Participant

    Hi Nathan.

    This can be achieved by writing a custom add-on that will handle this.

    I have quickly composed an example add-on for you – https://github.com/Arsenal21/stripe-payments-enhancements/releases/tag/0.0.12. Just download .zip file and install it as a normal WP plugin.

    The add-on checks if custom field and email field match. If not, it shows error and blocks form submit. Feel free to alter it per your needs.

    August 10, 2021 at 11:47 am #4157
    facet5
    Participant

    That’s fantastic – thank you.
    And thanks for the quick response!

  • Author
    Posts
Viewing 3 posts - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.
Log In

Primary Sidebar

Featured Addons and Extensions

  • Subscription Payments Addon
  • Additional Custom Fields
  • Secure Downloads Addon
  • Apple Pay, Google Pay, Afterpay

Addon Bundle

Stripe Payments Addon Bundle

Support Links

  • Support Forum
  • Support Contact

Search

Copyright © 2023 | Stripe Plugins | A member of the Tips and Tricks HQ family.