Announcement

Collapse
No announcement yet.

Only allow only specific email domain registration

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Only allow only specific email domain registration

    I'd like to offer sign-up access to select business associates - based on their corporate email address domain - rejecting all others.

    Can this be done? I don't want to have to approve/deny each account.

    Thanks!

  • #2
    Sorry, there is no function to do this in vB. This requires modifying the code. We cannot officially support code modifications or forums running modified code, however you can try searching or asking for help with this over at www.vbulletin.org.
    Steve Machol, former vBulletin Customer Support Manager (and NOT retired!)
    Change CKEditor Colors to Match Style (for 4.1.4 and above)

    Steve Machol Photography


    Mankind is the only creature smart enough to know its own history, and dumb enough to ignore it.


    Comment


    • #3
      Really? [strike]1[/strike] a few lines of Javascript in the Registration template would solve this problem.


      By the way...

      test
      [strike]test[/strike]
      [strikethru]test[/strikethru]
      [-]test[/-]

      Why does vB.com have no strikethru bbCode? It had [striketest] for months.
      Last edited by feldon23; Wed 8 Jun '11, 11:03pm.

      Comment


      • #4
        Then perhaps you could share this modification with the rest of the class.
        Steve Machol, former vBulletin Customer Support Manager (and NOT retired!)
        Change CKEditor Colors to Match Style (for 4.1.4 and above)

        Steve Machol Photography


        Mankind is the only creature smart enough to know its own history, and dumb enough to ignore it.


        Comment


        • #5
          In the register.php file, I would edit this area to check for correct email domain.

          Code:
          	// check for matching email addresses
          	if ($vbulletin->GPC['email'] != $vbulletin->GPC['emailconfirm'])
          	{
          		$userdata->error('emailmismatch');
          	}
          Then edit the emailmismatch phrase to explain the possible error is an incorrect domain.

          Comment


          • #6
            Steve,

            Add this to the <form> tag:

            Code:
            onSubmit="return checkEmail(this)"
            and in the Javascript code, something like this:

            Code:
            function checkEmail(str) {
               var x=(str.indexOf("domain.com") > 2);
               if (x==null || x=="")
              {
              alert("Registration on this forum is only for employees of domain.com.");
              return false;
              }
            }
            It wouldn't be bulletproof but just adding a Javascript check to the registration page on the e-mail address field would keep out most people. And if he had it set to e-mail him every time a new member registers, he'd see when someone registers with a non-company e-mail address.

            Comment

            widgetinstance 262 (Related Topics) skipped due to lack of content & hide_module_if_empty option.
            Working...
            X