Conditional Registration - Pass Test

17 years 8 months ago #18579 by oak21
Hello all,

I wonder if anybody hacked CB in the way that a registering person have to pass (with some level of success) a test, before he's allowed to register.

I have some tips from Joomla phorum and ideas, just want to know whether I'm not following somebody's steps...

Thanks, Oak

Please Log in to join the conversation.

17 years 8 months ago #18606 by mikko
Replied by mikko on topic Re:Conditional Registration - Pass Test
No need to hack, just write a plugin.


mikko

Please Log in to join the conversation.

17 years 8 months ago #18653 by oak21
Replied by oak21 on topic Re:Conditional Registration - Pass Test
Well, I'm not sure I'll be able to do it now, I'm quite new to Joomla...

Naturaly, I would redirect the link in CB Login menu ("Get Account" or so) to my extra script wich I believe I can inherit to Joomla (add "defined '_VALID_MOS' or die" stuff) and if the test is succesfull, send it back to CB registration page. But if I want to be serios about security, I will have to modify this page to check for control code (generated, defined by my, passed to CB join-form).
That's mean I will have to modify some CB files. So I have maybe stupid question - when creating plug-in, I will have to replace (during installation) those CB files, which should be modified?
I think my skills are not good enogh to create Joomla backend dialog to allow administrators to change the test questions & required success level, but I can put it into db via phpmyadmin and figure it out later (and so eventual users can :-D).
OK, I'm gonna have a look on that right now. I will start with porting the test scripts from my old [own] CMS.

Please Log in to join the conversation.

17 years 8 months ago #18658 by mikko
Replied by mikko on topic Re:Conditional Registration - Pass Test
See the download for API documentation. There is an example of field validation. Similarly, you could write a valitation plugin that validates several fields agaisnt what ever you wish.

For plugins you do not need to modify the core.

mikko

Please Log in to join the conversation.

17 years 8 months ago #18674 by oak21
Replied by oak21 on topic Re:Conditional Registration - Pass Test
I'm not sure I understand you well, I will have a closer look at that.
But I hope you didn't meant to put the fields into the registration form and check them i.e. with Javascript.
You need to tell the user why you're putting the test in and actually that it is a test. Ideally, it should be on different pages, separately from the join-form. Also you shouldn't store the test data, as this might upset some users (although it's silly, human mind works this way).

Thanks, I'll see what I can do.

Oak

Please Log in to join the conversation.

17 years 8 months ago #18693 by mikko
Replied by mikko on topic Re:Conditional Registration - Pass Test
You can do this for example in the following way by writing a plugin.

Make the plugin create a button "take test" and create a hidden field by the button. When user presses the button, a pop-up opens and some kind of test is shown. User makes the test and when the window is closed, javascipt is used to insert the test value to the hidden field in the form.

When teh form is submtted, the plugin first checks the hidden field on the server side after which the value is erased.

mikko

Please Log in to join the conversation.

Moderators: beatnantkrileon
Time to create page: 0.192 seconds

Facebook Twitter LinkedIn