REW Steven's Blog: PHP Programing
Input Validation
A very important concept in programing a system that will be used by people is Input Validation. When programmers miss this it can make life difficult for others trying to deal with the data.
As I deal with IDX Data I come across this a lot. I recently had a feed with 32 different spellings of a city name. Many of them were just typos like a semicolon (;) instead of an l ( the keys are next to each other on most keyboards ). Other cases were misspellings or variations of a name. An example would be "Saint James", "St. James", and "St James" ( without a period after St ).
If the MLS Board had Input Validation then users of the system would select the city from a list. This would fix more than just they typos and variations on the same name, it would…
Some Things To Know About IE 7
When using javascript in IE 7, you don't need to use getElementById
Thus in IE 6 you would do:
var city = document.getElementById('city');
alert(city.innerHTML);
</script>
And in IE 7 you can do
alert(city.innerHTML);
</script>
city is automatically an object pointing to the HTML tag with the id of that name.
This also means that if you accidentally use a variable with the same name as an id of an element, you will get errors.
I'm sure this gives rise to some kind of security flaw.
REW Blogs User Stats
Currently Online Users:
0
Total Users:
2,389
Entries:
7,601
Unique Views:
6,441,683
Total Views:
6,779,144
Total Comments:
9,372
Total REW Points:
510
I am a PHP / MySQL Programmer for Real Estate Webmasters. I program custom IDX solutions as well as many other custom features on our clients websites. Read More
- This User's Stats
-
Blog Entries: 24Average Blog Rating: 4Unique Views: 12,653Total Views: 13,491Comments Posted: 14Comments Received: 25REW Points: 0
Contact Me
RSS Feed
Top Rated
REW Blogs RSS Feed