Products

Solutions

Resources

Partners

Community

Blog

About

QA

Ideas Test

New Community Website

Ordinarily, you'd be at the right spot, but we've recently launched a brand new community website... For the community, by the community.

Yay... Take Me to the Community!

Welcome to the DNN Community Forums, your preferred source of online community support for all things related to DNN.
In order to participate you must be a registered DNNizen

HomeHomeUsing DNN Platf...Using DNN Platf...Administration ...Administration ...Confirm Email AddressConfirm Email Address
Previous
 
Next
New Post
2/18/2014 6:31 AM
 
There are a number of things that need to be done to make this sort of thing work with the existing registration module.
Just creating a new data profile type and an extra field would not in itself achieve the result you are looking for.
There are things going on in the registration module that would break if not handled correctly.

These are the steps that going down this sort of route would likely require.

1. Create a new data profile type control -- this would need to be done in c# - and be called something like myControls.WebControls.emailComparerControl
This controller could be based on the existing DotNetNuke.UI.WebControls.TextEditControl control with some client side code to handle the validation

Have a look at http://www.codeproject.com/Articles/2... - it talks about how to inject a validator as part of a control - in this case i would maybe inject a custom validator - that uses some client side script to do the validation

Have a look at http://msdn.microsoft.com/en-us/libra...(v=vs.110).aspx it talks about how to use a custom validator in code.

Either way - the trick is going to making sure it can find the Email field - since this field is dynamically registered - there is going to maybe need to be a DOM search to find the right field - in this case its going to be ID ends in 'Email_TextBox' - might be jquery is the quickest route here.

Regardless - once you got this control coded and compiled or loaded in /app_code/ then you need to register it with dnn.

2. Create a new data profile type - call it say EmailComparerType - this part is done in the Host -> Lists section
This data profile type will need to reference the new controller you created in step 1

3. Create a new User Profile field in Admin->Site Settings -> User Profile - call it EmailComparer and set its data type to EmailComparerType - also make sure its an admin only field for visibility.

You can also put your tooltip and error message defaults in here for later

4. Now in the same User Profile area - up near the top you need to switch the registration type from Standard to Custom.
Then in the field below you put in the name of the fields to be shown on the registration page - Username, Password, PasswordCompare,Email, and the new EmailComparer you created in step one

---------------

Assuming the code you created in the emailComparerControl is correct - the next time you browse to the registration page you should see your new fields - and your custom control should automatically do its thing as part of the automated validation processes.
 
New Post
2/18/2014 6:41 AM
 
But to be honest - by the time you spent a week stuffing around trying to make that all work - you would have been better off maybe just looking for a 3rd party custom registration module on http://store.dnnsoftware.com/home/pro...

have a look at these they may do what you need out of the box.
http://store.dnnsoftware.com/home/pro...
http://www.datasprings.com/dynamicreg... - does just about every sort of possible rego requirement imaginable.
 
New Post
2/18/2014 6:51 AM
 

Or to even be more honest - there is nothing that special about a DNN registration module.

You could probably code an entire working module in less time that it takes to stuff around with the above.

1. stick some fields on a page.

2. stick some validation on the fields

Rip the code out of the core registration module  /DesktopModules/Admin/Security/Register.ascx.cs for the following methods :

private void CreateUser() {...}

and 

private void CreateUser() { ... }

And modify to your needs - you need to create a couple of local properties and populate a userinfo user control manually from your fields on the form.

But again - nothing that could not be done quite easily if that was your intent

Westa

 
New Post
2/18/2014 6:56 AM
 

Westa,

firstly thank you for detailed and excellent replies!

I will work through your explanations and suggestions, I think I understand the basic principles..

Will report back here when done ...

Regards



 
Previous
 
Next
HomeHomeUsing DNN Platf...Using DNN Platf...Administration ...Administration ...Confirm Email AddressConfirm Email Address


These Forums are dedicated to discussion of DNN Platform and Evoq Solutions.

For the benefit of the community and to protect the integrity of the ecosystem, please observe the following posting guidelines:

  1. No Advertising. This includes promotion of commercial and non-commercial products or services which are not directly related to DNN.
  2. No vendor trolling / poaching. If someone posts about a vendor issue, allow the vendor or other customers to respond. Any post that looks like trolling / poaching will be removed.
  3. Discussion or promotion of DNN Platform product releases under a different brand name are strictly prohibited.
  4. No Flaming or Trolling.
  5. No Profanity, Racism, or Prejudice.
  6. Site Moderators have the final word on approving / removing a thread or post or comment.
  7. English language posting only, please.
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out