tracker issue : CF-3944862

select a category, or use search below
(searches all categories and all time range)

isValid validates invalid email address

| View in Tracker

Status/Resolution/Reason: Closed/Withdrawn/NotABug

Reporter/Name(from Bugbase): Tushar Bhaware / Tushar Bhaware (Tushar Bhaware)

Created: 02/25/2015

Components: Language

Versions: 11.0

Failure Type:

Found In Build/Fixed In Build: CF11_Final /

Priority/Frequency: Major / All users will encounter

Locale/System: English / Win Vista Home Basic

Vote Count: 1

Problem Description:
<cfdump var="#isValid("email","test@testdomain")#">
<cfdump var="#isValid("email","test@testdomain.a")#">

Actual Result:

Expected Result:

----------------------------- Additional Watson Details -----------------------------

Watson Bug ID:	3944862

External Customer Info:
External Company:  
External Customer Name: Tushar
External Customer Email:  
External Test Config: My Hardware and Environment details:

Server Product	ColdFusion

Version	11,0,04,293328

Tomcat Version

Edition	Developer  

Operating System	Windows Vista  

OS Version	6.0  

Update Level	C:/ColdFusion11/cfusion/lib/updates/chf11000004.jar  

Adobe Driver Version	5.1.3 (Build 000094)  

Java Version	1.7.0_55



isValid function validating incorrect email address. I didn't understand which product area i should select and since it was compulsory, I have selected the one I found most appropriate.
Comment by External U.
8279 | February 25, 2015 12:25:58 AM GMT
This is very common thing and i think every language have this kind of validation but no language makes such mistakes while doing so. If one have to do server side validation manually on platform like CF, its not only annoying but shameful. Its not opensource and freeware language. It should be fixed on priority basis.
Vote by External U.
8285 | February 25, 2015 12:46:23 AM GMT
Unless I'm missing something, both of those email addresses *are* valid. What's supposedly wrong with them?
Comment by External U.
8280 | February 25, 2015 05:30:20 PM GMT
OMG! I am embarrassed. I got to learn checking out all the possibilities and the possibility of I might be wrong. The reason I thought these emails are not valid because it emails are invalid because absence of TLD or presence of invalid TLD. I have also tested for one possibility in PHP language which was showing invalid email. The PHP code i tested is <?php $email = "test@test"; if (!filter_var($email, FILTER_VALIDATE_EMAIL)) { $emailErr = "Invalid email format"; } else { $emailErr = "valid"; } echo $emailErr; ?> But after your comment, I searched and found out that I am wrong. I am not sure why PHP gives it invalid email format. And there is no way to withdraw this bug.
Comment by External U.
8281 | February 26, 2015 01:32:40 AM GMT
Don't be embarrassed mate: everyone makes mistakes! PHP is a fairly jerry-built sort of language, so not surprised it doesn't get things right all the time.
Comment by External U.
8282 | February 26, 2015 05:40:03 AM GMT
Going by the comments below, will be closing this bug. test@testdomain and test@testdomain.a are valid email addresses.
Comment by Immanuel N.
8283 | March 08, 2015 11:58:19 PM GMT
@Immanuel Noel, Thank you. Question: Can you tell me how did you withdrawn the bug? I couldn't find any option to withdraw this bug.
Comment by External U.
8284 | March 09, 2015 12:21:33 AM GMT