Joomla registration with contentBuilder check pass

  • jok111
  • Topic Author
  • Offline
  • Junior Boarder
  • Junior Boarder
  • Posts: 25
  • Thank you received: 0

jok111 created the topic: Joomla registration with contentBuilder check pass

Hi,
I saw the Tutorial: ContentBuilder Joomla! Registration And Profiles.
I did it by myself and everything is working fine.
But I have a little problem. I want to force the user to type in a password with a minimum length and if possible some extra character. (like within joomla registration) How can I do this with the contentBuilder?
Do you have any hint for me?

Thank and regards
Jochen
#160338
  • Posts: 3568
  • Karma: 87
  • Thank you received: 288

Tihomir replied the topic: Joomla registration with contentBuilder check pass

Hello there,

at list of your elements you should go to password element ( column editable ) and then on the top of window ( editable ) you can see option and scripts. Go to the scripts and there's a place ( INIT JS) where you can add your custom JS script for special charactert or whatever you want to do at your element.

Also you can find in attachment an image how it should look like.

Let us know if that worked for you.

Kind regards

===============================================
Support Crosstec and get ALL EXTENSIONS and professional support for just $5
Here!
===============================================
Regards
Tihomir
==========================================
+++ Purchase Professional Support: crosstec.org/en/support/purchase-additional-support.html +++
#160341
Attachments:
  • jok111
  • Topic Author
  • Offline
  • Junior Boarder
  • Junior Boarder
  • Posts: 25
  • Thank you received: 0

jok111 replied the topic: Joomla registration with contentBuilder check pass

Thank you very much for your answer.
Unfornutally I'm a beginner concerning JS. Do you have perhaps an example.
For example I want to check that the user has entered 8 characters.
KInd regards
Jochen
#160350
  • jok111
  • Topic Author
  • Offline
  • Junior Boarder
  • Junior Boarder
  • Posts: 25
  • Thank you received: 0

jok111 replied the topic: Joomla registration with contentBuilder check pass

I think my question is not quite clear. Sure I can make such a check with JS.
My problem is that I do not know the interface to contentBuilder. Is it the same as
in Breezingforms (something like: ff_getElementByName('FELDNAME') ) or something else
to access an element. And how can I publish an error message for the form if the check went wrong.
(is there perhaps any Docu about that). Or is it better to use BreezingForms to realize a registration form?
Kind regards
Jochen
#160367
  • Posts: 3568
  • Karma: 87
  • Thank you received: 288

Tihomir replied the topic: Joomla registration with contentBuilder check pass

Ok,

1) about the Breezing Forms:
in your element you can see a part for validation => go to the custom validation
There you can write the code , for example ( at least 10 characters )
function ff_nameOfElement_validation(element, message)
{
     if(element.value.length > 10)
     {
          return '';
     }
     return 'Please enter at least 10 characters';
}

well, unlike BF, Content Builder has no concept (yet) to do that, so you have to do something like this.

At your element you can see editable column, open it and on the top of the window you should see options and script. Go to the scripts and into Init Js put the code similar to this one:
var el = jQuery(contentbuilder._("elementname")).on('change', function(){
    if(jQuery(this).val().length < 11){
       jQuery(this).before('<div style="color:red">Please add at least 10 characters.</div>');
       contentbuilder.onSubmit( function() { return false; } )
    }
});

You should see red validation msg above the filed.

Also you can find in attachment simple form ( BreezingForm ) how it should look like.

Let us know if that worked for you.

Kind regards

===============================================
Support Crosstec and get ALL EXTENSIONS and professional support for just $5
Here!
===============================================
Regards
Tihomir
==========================================
+++ Purchase Professional Support: crosstec.org/en/support/purchase-additional-support.html +++
#160383
Attachments:
The following user(s) said Thank You: jok111
  • jok111
  • Topic Author
  • Offline
  • Junior Boarder
  • Junior Boarder
  • Posts: 25
  • Thank you received: 0

jok111 replied the topic: Joomla registration with contentBuilder check pass

Thank you very much for that useful information.
One thing, after writting a wrong password I can see the red text above the field.
Is there a possibility do delete that red text again when the password is written ok after(perhaps
insied an else case)?

Kind regards
Jochen
#160387
Moderators: tomeperica
Time to create page: 0.075 seconds

New Icon Packs Category!

Crosstec is now offering icon packs.

If you are a paying subscriber, icon packs are automatically added to your account.

Check out our icon packs page!

Live Support Chat Opened!

Join our Discord chat here to receive live support and talk directly to the team!

Summer Sale!

50% discount on all of our extension subscription plans, templates and icon packs!

Get Your Subscription Here

News and Updates

Get informed about new downloads, updates and more in our News and Updates newsletter.

All Extensions Subscription

Get 1 year access to all of our current and future products and 1 year of professional support -- 99 for just 49! (Summer Sale)

No support per domain or website installation limits! Includes all of our current and future Joomla!® extensions, Joomla!® templates for the duration of your membership. This means, by purchasing an All Extensions Subscription you'll have it all covered!

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!

Live Support Chat Opened!

Join our Discord chat here to receive live support and talk directly to the team!

Community Reward

Help us to create new extensions and plugins! With only $5 you help us a lot and get unlimited download access to all of our products, professional support and even more. Get your reward now!

Read More Here