Welcome, Guest. Please Login or Register.
May 06, 2024, 07:40:49 PM
Home Help Search Log in Register
News: If you are still using YaBB SE, please consider upgrading to SMF as soon as possible.

YaBB SE Community  |  Development  |  Completed mods  |  [Done 1.4.1] Email Validation v.2 « previous next »
Pages: [1] Reply Ignore Print
Author Topic: [Done 1.4.1] Email Validation v.2  (Read 4680 times)
opus
Jr. Member
**
Posts: 59


I'm an opus!

ICQ - 16116986 WWW
[Done 1.4.1] Email Validation v.2
« on: August 22, 2002, 06:58:22 PM »
Reply with quote

This is my first attempt at a mod.  So be kind  <grin>

Email Validate v0.2

- Added support for checking MSN email addresses

Simply adds checking for @ and . in an email address during registration and when a member updates his/her profile.

Three files are changed english.lng, Register.php and Profile.php.


<Edit file>
Sources\Register.php
</Edit>

<Search for>
   if(strstr($member['user'],"Guest")) { fatal_error("$txt[244] $member[user]");}
</Search>

<Add after>
   if(!eregi("^[_a-z0-9-]+(\.[_a-z0-9-]+)*@[a-z0-9-]+(\.[a-z0-9-]+)*(\.[a-z]{2,3})$", $member['email'])) {fatal_error("$member[user] $txt[500]"); }
</Add after>

<Edit file>
Sources\Profile.php
</Edit>

<Search for>
   if($member['email'] == '') { fatal_error("$txt[76]"); }
</Search>

<Add after>
   if(!eregi("^[_a-z0-9-]+(\.[_a-z0-9-]+)*@[a-z0-9-]+(\.[a-z0-9-]+)*(\.[a-z]{2,3})$", $member['email'])) {fatal_error("$member[user] $txt[500]"); }
</Add after>

<Search for>
                $member['yim'] = str_replace(" ","+",$member['yim']);
</search>

<add after>

                if ($member['msn'] != '')  {
                                if(!eregi("^[_a-z0-9-]+(\.[_a-z0-9-]+)*@[a-z0-9-]+(\.[a-z0-9-]+)*(\.
[a-z]{2,3})$", $member['msn'])) {fatal_error("$member[user] $txt[msn1]"); }
                                 }
</add after>

<Edit file>
english.lng
</Edit file>

<Search for>
$locale = "en_US";
</Search for>

<Add after>
$txt['msn1'] = "please enter a valid MSN email address.";
</Add after>




or mod file:


http://www.scottmartin.cc/downloads/validate.zip
« Last Edit: August 29, 2002, 05:27:37 PM by opus » Logged

If I were two people I would still be busy.
Wiziwig
Sr. Member
****
Posts: 407


Programmer and Users Liason and Manager

WWW
Re:[BETA 1.4.1] Email Validation
« Reply #1 on: August 23, 2002, 02:22:43 AM »
Reply with quote

Hey this is a nifty ideal! Thanks a bunch! question.. msn users tend to enter in thier msn names without the @mailaddress.com in the msn under profile. .I tried to place your string under the msn input field. Great ideal but I need to have it check the user input for strings, and if it finds none to skip the error processs. Can you help with this tweak???

        $member['msn'] = str_replace(" ","+",$member['msn']);

// My Atempts to control the msn flaw
//   if(!eregi("^[_a-z0-9-]+(\.[_a-z0-9-]+)*@[a-z0-9-]+(\.[a-z0-9-]+)*(\.[a-z]{2,3})$", $member['msn'])) {fatal_error("$member[user] $txt[555]"); }
//
Logged

opus
Jr. Member
**
Posts: 59


I'm an opus!

ICQ - 16116986 WWW
Re:[BETA 1.4.1] Email Validation
« Reply #2 on: August 23, 2002, 03:27:14 AM »
Reply with quote

I will look at it in the morning.  I am sure it would not be difficult to add.   Maybe I can find a way to check for msn.com or hotmail.com while it is at it.
« Last Edit: August 23, 2002, 03:28:39 AM by opus » Logged

If I were two people I would still be busy.
Wiziwig
Sr. Member
****
Posts: 407


Programmer and Users Liason and Manager

WWW
Re:[BETA 1.4.1] Email Validation
« Reply #3 on: August 23, 2002, 03:37:40 AM »
Reply with quote

checking for specific @mail's would not be good. My msn account uses my yahoo mail address. It'll be great to just check to make sure they've put somekind of @mailaddress.com on the profile.. And when it errors and they click back, the rest of the profile information should be preserved..
Logged

opus
Jr. Member
**
Posts: 59


I'm an opus!

ICQ - 16116986 WWW
Re:[BETA 1.4.1] Email Validation
« Reply #4 on: August 23, 2002, 03:44:17 AM »
Reply with quote

I see.   ;)  I didn't know that you could use something besides msn or hotmail for a MSN account.  I don't even have a computer with windows on it (give me a mac or a *nix box anyday)  Like I said I will look closer at the code in the AM.  my eyes are starting to cross tonight.

Logged

If I were two people I would still be busy.
opus
Jr. Member
**
Posts: 59


I'm an opus!

ICQ - 16116986 WWW
Re:[BETA 1.4.1] Email Validation v0.2
« Reply #5 on: August 25, 2002, 07:28:54 AM »
Reply with quote

Ok.. the msn update has been made. Give it a try and let me know.  The mod file has been updated too.
Logged

If I were two people I would still be busy.
Wiziwig
Sr. Member
****
Posts: 407


Programmer and Users Liason and Manager

WWW
Re:[BETA 1.4.1] Email Validation
« Reply #6 on: August 25, 2002, 10:46:01 AM »
Reply with quote

Great job and THANK YOU! Your mod has some odd (unix?? mac??) characters along the last few lines..  For the rest of us messy dos people it's:

   if ($member['msn'] != '')  { if(!eregi("^[_a-z0-9-]+(\.[_a-z0-9-]+)*@[a-z0-9-]+(\.[a-z0-9-]+)*(\.[a-z]{2,3})$", $member['msn'])) {fatal_error("$member[user] $txt[msn1]"); } }

Thank you very much! :)
Logged

opus
Jr. Member
**
Posts: 59


I'm an opus!

ICQ - 16116986 WWW
Re:[BETA 1.4.1] Email Validation
« Reply #7 on: August 25, 2002, 02:14:25 PM »
Reply with quote

What ever they were it has been fixed now.
Logged

If I were two people I would still be busy.
opus
Jr. Member
**
Posts: 59


I'm an opus!

ICQ - 16116986 WWW
Re:[Done 1.4.1] Email Validation v.2
« Reply #8 on: August 28, 2002, 01:59:56 PM »
Reply with quote

All done!  Time to start on a new mod   ;)
Logged

If I were two people I would still be busy.
da dude
Noobie
*
Posts: 21


wassup!!!!!

ICQ - 150059864dadude85@hotmail.com WWW
Re:[Done 1.4.1] Email Validation v.2
« Reply #9 on: August 28, 2002, 07:04:07 PM »
Reply with quote

there's a add after missing in the mod file  :-X :-\
says boardmod
Logged

don't ask me dude where's my car because i stole it
opus
Jr. Member
**
Posts: 59


I'm an opus!

ICQ - 16116986 WWW
Re:[Done 1.4.1] Email Validation v.2
« Reply #10 on: August 28, 2002, 07:19:45 PM »
Reply with quote

What ever I managed to do with the mod file I have fixed.  (and retested)  download the new one at the above link.
Logged

If I were two people I would still be busy.
iamdamnsam
Full Member
***
Posts: 225


RamchargerCentral.Com

WWW
Re:[Done 1.4.1] Email Validation v.2
« Reply #11 on: August 30, 2002, 08:24:25 PM »
Reply with quote

If this mod worked correctly you wouldn't need to validate email address structure, it would validate if the person registering is enter their own email address, not a fake one like [email protected].

http://www.yabb.info/community/index.php?board=158;action=display;threadid=11282
Logged

opus
Jr. Member
**
Posts: 59


I'm an opus!

ICQ - 16116986 WWW
Re:[Done 1.4.1] Email Validation v.2
« Reply #12 on: August 30, 2002, 08:55:04 PM »
Reply with quote

I don't see why they can't both be used.  I wrote this mostly because I was tired for getting bounced mail from people they don't know the difference between an email address and a screen name.  At least this way it makes them enter something that could be real.  I have not gotten one bounced mail since adding it.
Logged

If I were two people I would still be busy.
Wiziwig
Sr. Member
****
Posts: 407


Programmer and Users Liason and Manager

WWW
Re:[Done 1.4.1] Email Validation v.2
« Reply #13 on: August 30, 2002, 09:29:26 PM »
Reply with quote

With the problems they are having with that other mod, I refrain from using it for 1.4.1, ,

It would be nice if that mod project was validated and a closure was made to it's progress.

Logged

Pages: [1] Reply Ignore Print 
YaBB SE Community  |  Development  |  Completed mods  |  [Done 1.4.1] Email Validation v.2 « previous - next »
 


Powered by MySQL Powered by PHP YaBB SE Community | Powered by YaBB SE
© 2001-2003, YaBB SE Dev Team. All Rights Reserved.
SMF 2.1.4 © 2023, Simple Machines
Valid XHTML 1.0! Valid CSS

Page created in 0.041 seconds with 19 queries.