TOPIC:

contact form exclude wrong names 1 month 5 days ago #249918

  • Topic Author
  • Maddddin82
  • Offline
  • Fresh Breezer
  • Fresh Breezer
  • Posts: 3
  • Thanks: 0
I have the following question:
is it possible to exclude wrong names, e.g. Mickey Mouse, when creating forms? If so, how can this be done? Thank you for your help and best regards Martin

Please Log in or Create an account to join the conversation.

contact form exclude wrong names 1 month 5 days ago #249919

  • tihana.krivic's Avatar
  • tihana.krivic
  • Offline
  • Moderator
  • Moderator
  • Posts: 2267
  • Karma: 3
  • Thanks: 210
Hi,

you can exclude "Mickey Mouse" from form elements, using validation (if someone enter wrong name error message appears)
If you want this, I can point you in the right direction.

Regards,
Tihana

Please Log in or Create an account to join the conversation.

Last edit: Post by tihana.krivic.

contact form exclude wrong names 1 month 5 days ago #249920

  • Topic Author
  • Maddddin82
  • Offline
  • Fresh Breezer
  • Fresh Breezer
  • Posts: 3
  • Thanks: 0
Hi Tihana,

thank you for the info. If you can help me here, it would be great.
Thank you very much and best regards
Martin

Please Log in or Create an account to join the conversation.

contact form exclude wrong names 1 month 5 days ago #249921

  • tihana.krivic's Avatar
  • tihana.krivic
  • Offline
  • Moderator
  • Moderator
  • Posts: 2267
  • Karma: 3
  • Thanks: 210
Hi,

for example if you want exclude name Mickey Mouse from textfield.
1) go to this textfield->Properties->Validation->check Custom->Create code framework and put this:
function ff_nameoftextfield_validation(element, message)
{
    var wrongname = /\b(Mickey Mouse)\b/ig;
    if (wrongname.test(element.value)) {
        if (message=='') message = element.name+" contains a wrong name.\n";
        ff_validationFocus(element.name);
        return message;
    } // if
    return '';
} // ff_nameoftextfield_validation
Please replace nameoftextfield with name of your textfield (not title).

When someone enter name Mickey Mouse and click on Submit button, then error message will appear

Let me know if you need more help.

Regards,
Tihana

Please Log in or Create an account to join the conversation.

contact form exclude wrong names 1 month 5 days ago #249922

  • Topic Author
  • Maddddin82
  • Offline
  • Fresh Breezer
  • Fresh Breezer
  • Posts: 3
  • Thanks: 0
Hi Tihana,

thank you.

Regards Martin

Please Log in or Create an account to join the conversation.

  • Page:
  • 1
Moderators: ForumSupport
Time to create page: 0.046 seconds

BreezingForms Pro 1.4.7 for WordPress Released!

Available in the membership section.

September Discount!

Massive discounts on all subscriptions!

Get Your Subscription Here

Quick Links

Downloads

BreezingForms

ContentBuilder

BreezingCommerce

Templates

Documentation

BreezingForms

ContentBuilder

BreezingCommerce

Apprendre BreezingForms (French Community)

Apprendre et maîtriser BreezingForms par des tutoriels et exemples, le tout en français

breezingforms.eddy-vh.com

Questions et réponses sur les forums de l'AFUJ

AFUJ

Special Offer

Summer Sale! All subscriptions at a special price!

Includes prio support, all of our current and future Joomla!® extensions and Joomla!® templates for the duration of your membership.

Get it from here

3rd Party Discount - 25% Off

We help you to keep your costs under control. If you are a new member and purchased a form building tool from a different form vendor, then you'll get a 25% discount on our subscription plans.

How to receive the discount:

Send us a quick email to sales@crosstec.org with a proof of purchase (for example a paypal receipt), await payment instructions and enjoy your membership!