Leading blanks in a DOM property field

Discussion of the technology underlying the eValid solution.

Leading blanks in a DOM property field

Postby Lancean » Thu Mar 21, 2013 4:03 pm

Do leading blanks in a DOM property field ever cause eValid problems?
Lancean
 
Posts: 1
Joined: Thu Mar 21, 2013 3:59 pm

Re: Leading blanks in a DOM property field

Postby eValid » Fri Mar 22, 2013 9:48 am

This seems almost like a "leading question..." Have you seen a problem with how strings that start with a blank are handled?

In any case, yes, there CAN be some issues with how strings where there is an actual leading blank in the property/attribute value string.

We considered, at one point, stripping leading blanks...kind of a process of "normalizing" internal strings, and then we found that (believe it or not) some websites were specifically relying on that trick as a way to hide information. As web application testers, remember, we don't get to complain about what we're faced with; we have to find a way to test it under the assumption that, however crazy a process is, it is in the website or web application and we have to deal with it as it is!

Hence, in eValid any leading blanks in a property/attribute value are treated as significant.

Trailing blanks are a different matter. For practical reasons if you ask whether " This" is a substring of " This " or " This " [one and then multiple trailing blanks] the eValid behaves correctly and only compares the characters in the shorter of the two strings. In this case the answer is yes in both cases. This makes the trailing blanks problem sort of "disappear." But eValid will consider a trailing blank like this " This " as significant (note that this is a 6-character string).

Hope this helps but it can be awfully confusing until you get the knack of it.

eValid Technology Group
eValid
 
Posts: 2396
Joined: Tue Jan 01, 2008 12:48 pm
Location: USA


Return to Technology

Design Downloaded from free phpBB templates | free website templates | Free Web Buttons