330 reputation
26
bio website ee.gg
location Colchester, United Kingdom
age 27
visits member for 3 years, 6 months
seen Nov 25 at 13:02

Mar
15
comment Should I check integrity in my application code or defer to the database?
Well, I think you'd just name all your constraints, then when the DB gives you violated username_valid_char, you lookup friendly_errors['username_valid_char'].
Mar
15
awarded  Editor
Mar
15
revised Should I check integrity in my application code or defer to the database?
Clarified escaping of arguments to parameterized SQL.
Mar
15
comment Should I check integrity in my application code or defer to the database?
You're right about the password issue! My silly example was fortuitous for finding that example. I don't buy the injection argument; obviously that should just be properly escaped.
Mar
15
asked Is there a name for this kind of database constraint? “Functional foreign key”? And is it a good idea?
Mar
15
awarded  Supporter
Mar
15
asked Should I check integrity in my application code or defer to the database?
Mar
6
awarded  Popular Question
Nov
28
awarded  Critic
Jun
23
awarded  Yearling
Jun
27
comment Why not XHTML5?
Over the HTML4 specification, yes. But my point is that XHTML1.1 already improved on that. Tools/libraries to handle HTML tend to be like BeautifulSoup -- while wonderful tools, they should die along with the pages they were made to parse.
Jun
27
comment Why not XHTML5?
@Joeri, your position seems to be that of the HTML5 spec, taken to its insane logical conclusion. "HTML5 redefines the parsing rules to make all input valid" -- it doesn't. The concept of parsing errors still exists. "If syntax errors are impossible, a whole class of bugs are ruled out from the start" -- maybe this is parody? This logic is what I sarcastically paraphrased in my comment to @pthesis' answer. Yes, the class of syntax errors is removed, to be replaced by a larger class of browser syntax correction errors.
Jun
27
comment Why not XHTML5?
@zzzzBov, you're most definitely not the only one who's glad, and that's why I asked this question in the first place. Also: you wouldn't seriously write <!DOCTYPE html>Hello World, would you? Try that on this validator.
Jun
27
comment Why not XHTML5?
@zzzzBov, your analogy with published books is weird. Why should an HTML parser be any more forgiving than a parser for [any other language here], where a syntax error is met with an error message? Imagine the chaos we would be in if our C compilers tried their best to silently reinterpret broken syntax.
Jun
24
awarded  Good Question
Jun
24
comment Why not XHTML5?
The story of browsers' competing sloppiness is true enough. But here's the thing: that's why the standards-geeks exist. If all browsers had enforced the straight and narrow from the start, organizations like the W3C wouldn't need to be here to keep things under control. The whole point of the standards is damage-control; for the standards body to give in and accept sloppiness defeats its very purpose.
Jun
23
awarded  Nice Question
Jun
23
comment Why not XHTML5?
Yeah. My summary of that story would be, "Hey, no-one's conforming to the specification. Maybe we could get them to conform to the specification by specifying that people can make any errors they want. Then finally all our documents will be error-free and standards-compliant." No good can come from writing a specification with the initial assumption that no-one respects specifications.
Jun
23
awarded  Student
Jun
23
asked Why not XHTML5?