Re: Email validation

2017-11-28 Thread Vino via Digitalmars-d-learn
On Wednesday, 29 November 2017 at 05:22:34 UTC, Dmitry wrote: On Wednesday, 29 November 2017 at 03:49:56 UTC, codephantom wrote: string domainRequired = "@hotmail.com"; string emailAddress = "vino.bhee...@hotmail.com"; emailAddress.endsWith(domainRequired) ? writeln("domain ok")

Re: Email validation

2017-11-28 Thread Dmitry via Digitalmars-d-learn
On Wednesday, 29 November 2017 at 03:49:56 UTC, codephantom wrote: string domainRequired = "@hotmail.com"; string emailAddress = "vino.bhee...@hotmail.com"; emailAddress.endsWith(domainRequired) ? writeln("domain ok") : writeln("invalid domain"); Also you need check that

Re: Email validation

2017-11-28 Thread codephantom via Digitalmars-d-learn
On Tuesday, 28 November 2017 at 18:47:06 UTC, Vino wrote: Hi All, Can you please provide me some example on who to validate an email address as the document dose not have an example for the same Ex: vino.bhee...@hotmail.com Conditions : The domain should contain only "hotmail.com" The

Re: Email validation

2017-11-28 Thread codephantom via Digitalmars-d-learn
On Tuesday, 28 November 2017 at 22:42:27 UTC, Mike Wey wrote: isMail only checks the formatting of the email address and optionally if the domain has a MX record. I don't believe MX validation (checkDns) is implemented yet.

Re: Email validation

2017-11-28 Thread codephantom via Digitalmars-d-learn
On Tuesday, 28 November 2017 at 18:47:06 UTC, Vino wrote: Hi All, Can you please provide me some example on who to validate an email address as the document dose not have an example for the same Ex: vino.bhee...@hotmail.com Conditions : The domain should contain only "hotmail.com" The

Re: Email validation

2017-11-28 Thread codephantom via Digitalmars-d-learn
On Tuesday, 28 November 2017 at 19:32:40 UTC, Vino wrote: Can you provide me a example, as the link does not have any examples. From, Vino.B btw... yes documentation is an acknowledged issue with regards to phobos...but..that aside...it can also be useful (and wise) to look at the unit

Re: Email validation

2017-11-28 Thread Mike Wey via Digitalmars-d-learn
On 28-11-17 20:32, Vino wrote: On Tuesday, 28 November 2017 at 18:51:50 UTC, Rene Zwanenburg wrote: On Tuesday, 28 November 2017 at 18:47:06 UTC, Vino wrote: Hi All, You can do this easily using the std.net.isemail module: https://dlang.org/phobos/std_net_isemail.html Hi Rene,  Can you

Re: Email validation

2017-11-28 Thread Vino via Digitalmars-d-learn
On Tuesday, 28 November 2017 at 18:51:50 UTC, Rene Zwanenburg wrote: On Tuesday, 28 November 2017 at 18:47:06 UTC, Vino wrote: Hi All, You can do this easily using the std.net.isemail module: https://dlang.org/phobos/std_net_isemail.html Hi Rene, Can you provide me a example, as the link

Re: Email validation

2017-11-28 Thread Rene Zwanenburg via Digitalmars-d-learn
On Tuesday, 28 November 2017 at 18:47:06 UTC, Vino wrote: Hi All, You can do this easily using the std.net.isemail module: https://dlang.org/phobos/std_net_isemail.html

Email validation

2017-11-28 Thread Vino via Digitalmars-d-learn
Hi All, Can you please provide me some example on who to validate an email address as the document dose not have an example for the same Ex: vino.bhee...@hotmail.com Conditions : The domain should contain only "hotmail.com" The email address should contain the symbol "@" From, Vino.B