Author Topic: Registration without email field  (Read 5868 times)

0 Members and 1 Guest are viewing this topic.

Offline karimun

  • Newbie
  • *
  • Posts: 49
    • View Profile
    • http://www.at6pm.com
Registration without email field
« on: June 25, 2005, 08:59:16 PM »
I want to make the email field optional:
The script should not return an error message when no email was typed.

I tried to make some changes to register.php - without success. Thanks in advance.

Offline V@no

  • If you don't tell me what to do, I won't tell you where you should go :)
  • Global Moderator
  • 4images Guru
  • *****
  • Posts: 17.849
  • mmm PHP...
    • View Profile
    • 4images MODs Demo
Re: Registration without email field
« Reply #1 on: June 25, 2005, 11:09:05 PM »
comment out or remove this from register.php
Code: [Select]
      $msg .= (($msg != "") ? "<br />" : "").$field_error = preg_replace("/".$site_template->start."field_name".$site_template->end."/siU", str_replace(":", "", $lang['email']), $lang['field_required']);
      $error = 1;
Your first three "must do" before you ask a question:
Please do not PM me asking for help unless you've been specifically asked to do so. Such PMs will be deleted without answer. (forum rule #6)
Extension for Firefox/Thunderbird: Master Password+    Back/Forward History Tweaks (restartless)    Cookies Manager+    Fit Images (restartless for Thunderbird)

Offline karimun

  • Newbie
  • *
  • Posts: 49
    • View Profile
    • http://www.at6pm.com
Re: Registration without email field
« Reply #2 on: June 26, 2005, 12:36:40 AM »
Internal Server Error ..

I change this piece:
Code: [Select]
    else {
      $msg .= (($msg != "") ? "<br />" : "").$field_error = preg_replace("/".$site_template->start."field_name".$site_template->end."/siU", str_replace(":", "", $lang['email']), $lang['field_required']);
      $error = 1;
    }

to this:
Code: [Select]
else {}
... sorry for my ignorance  :roll:

Offline V@no

  • If you don't tell me what to do, I won't tell you where you should go :)
  • Global Moderator
  • 4images Guru
  • *****
  • Posts: 17.849
  • mmm PHP...
    • View Profile
    • 4images MODs Demo
Re: Registration without email field
« Reply #3 on: June 26, 2005, 01:50:46 AM »
ok, remove else {} as well.
Your first three "must do" before you ask a question:
Please do not PM me asking for help unless you've been specifically asked to do so. Such PMs will be deleted without answer. (forum rule #6)
Extension for Firefox/Thunderbird: Master Password+    Back/Forward History Tweaks (restartless)    Cookies Manager+    Fit Images (restartless for Thunderbird)

Offline karimun

  • Newbie
  • *
  • Posts: 49
    • View Profile
    • http://www.at6pm.com
Re: Registration without email field
« Reply #4 on: June 26, 2005, 08:57:06 AM »
Strange things:
I have removed the complete else { .. } part. Now the registration without email is possible (new user appears im my memberlist) but I receive a Internal Server Error right after the submit button is clicked.  :?

Its a fresh installation so there should be no conflicts with other Mods in register.php.

Offline V@no

  • If you don't tell me what to do, I won't tell you where you should go :)
  • Global Moderator
  • 4images Guru
  • *****
  • Posts: 17.849
  • mmm PHP...
    • View Profile
    • 4images MODs Demo
Re: Registration without email field
« Reply #5 on: June 26, 2005, 12:57:50 PM »
if its internal server error, without seeing the error logs there is no way to guess what could be wrong.
Your first three "must do" before you ask a question:
Please do not PM me asking for help unless you've been specifically asked to do so. Such PMs will be deleted without answer. (forum rule #6)
Extension for Firefox/Thunderbird: Master Password+    Back/Forward History Tweaks (restartless)    Cookies Manager+    Fit Images (restartless for Thunderbird)

Offline karimun

  • Newbie
  • *
  • Posts: 49
    • View Profile
    • http://www.at6pm.com
Re: Registration without email field
« Reply #6 on: June 26, 2005, 04:57:16 PM »
Ok V@no,
I will ask my host whether I can have access to it.