SHARE
Facebook X Pinterest WhatsApp

Server-Side e-mail Validation with ASP.

Jul 20, 2010
ServerWatch content and product recommendations are editorially independent. We may make money when you click on links to our partners. Learn More



Joco Vieira

This one is very simple….
but there is always someone trying to reach this code…. I hope you understand
the code.

1. First I have created a variable that at the end could give me if the
validation is ok or not ‘goby’.

2. So, I have used the
function InStr that gives me True Or False about any character inside
a String.

This one is very simple…. but there is always someone trying to reach this code…. I hope you understand the code.

3. So here is the code, use
it as you want

Dim goby
goby = 0 //Starting the goby string
    I f Len(session(“emailfrom”))
     else
        If InStr(1, session(“emailfrom”),
“@”, 1)
            
goby = 1
                Else
                   If
InStr(1,session(“emailfrom”), “.”, 1)
                      
goby = 1
                   End
If
        End If
End If
If goby 0 then // well , if goby 0 then something
must be wrong
     response.write “Bad E-Mail…”
End If

Recommended for you...

What Is a Container? Understanding Containerization
What Is a Print Server? | How It Works and What It Does
Nisar Ahmad
Dec 8, 2023
What Is a Network Policy Server (NPS)? | Essential Guide
Virtual Servers vs. Physical Servers: Comparison and Use Cases
Ray Fernandez
Nov 14, 2023
ServerWatch Logo

ServerWatch is a top resource on servers. Explore the latest news, reviews and guides for server administrators now.

Property of TechnologyAdvice. © 2025 TechnologyAdvice. All Rights Reserved

Advertiser Disclosure: Some of the products that appear on this site are from companies from which TechnologyAdvice receives compensation. This compensation may impact how and where products appear on this site including, for example, the order in which they appear. TechnologyAdvice does not include all companies or all types of products available in the marketplace.