WTFOTD
-
Alvaro Mendez wrote:
the problem is that if the user clicks the Stop button on the browser before the page comes back, the button stays disabled and he's stuck.
Stuck, like when you like a frozen railing kinda stuck?
cheers, Chris Maunder
CodeProject.com : C++ MVP
Chris Maunder wrote:
Stuck, like when you like a frozen railing kinda stuck?
Yeah, or like those people at the movies that walk into quicksand. :)
If [God] knows what we are going to do then we have no free will and are just characters in a play written by him. Without free will, morality for humans makes no sense. Without free will and morality, any sort of punishment or reward system loses any justification. Heaven and hell would be places where [God] could watch the souls he created, predestined just for eternal happiness or agony. - Mark Thomas
-
what the hell does WTFOTD mean? please, add a reference to it: http://www.urbandictionary.com/define.php?term=WTFOTD[^]
WTF Of The Day in coding, a WTF is a really obvious mistake, or really poor logic. I think this is the site that made the term famous: http://thedailywtf.com/[^]
"For fifty bucks I'd put my face in their soup and blow." - George Costanza
~ Web SQL Utility - asp.net app to query Access, SQL server, MySQL. Stores history, favourites.
-
Would of made a good post in the new "Subtle Bugs" forum. :)
Kicking squealing Gucci little piggy.
My most recent, favourite subtle bug is:
foreach (string s in myStrings); { col.Add(s); }
and wondering why my collection never gets populated. -
Ashley van Gerven wrote:
Well I'm actually showing a message next to the disabled button. And the thought had crossed my mind to include a 'try again' link to re-enable the button. But by the time they click stop, the request is already being processed, so kindof a catch 22.
I was thinking that one way to work around the possibility of the user clicking Stop may be to call setTimeout to reenable the Submit button after say, 15 seconds or so, depending on how long the round trip can take. I've seen some sites immediately redirect the user to a "Please wait" page which does the actual postback, but that may be overkill for your site. Regards, Alvaro
If [God] knows what we are going to do then we have no free will and are just characters in a play written by him. Without free will, morality for humans makes no sense. Without free will and morality, any sort of punishment or reward system loses any justification. Heaven and hell would be places where [God] could watch the souls he created, predestined just for eternal happiness or agony. - Mark Thomas
Both good ideas - thanks. Another idea that just sprang to mind is to just show a confirm() box on the second click saying something like 'you already submitted this form - do you want to re-submit?'.
"For fifty bucks I'd put my face in their soup and blow." - George Costanza
~ Web SQL Utility - asp.net app to query Access, SQL server, MySQL. Stores history, favourites.
-
ok this is mine... I'm embarrassed to post this but here goes:
BtnSubmit.Attributes.Add("onlick", "disableSubmit()");
I'm wondering why on hell it's not disabling the button... when I suddenly spot my typo :doh: DOH! Somehow I don't think the button is going to be licked any time soon! :laugh:"For fifty bucks I'd put my face in their soup and blow." - George Costanza
~ Web SQL Utility - asp.net app to query Access, SQL server, MySQL. Stores history, favourites.
Ashley van Gerven wrote:
Somehow I don't think the button is going to be licked any time soon!
Didn't Steve Jobs say, "We made the buttons look so good you would want to lick them"? So, the Mac has the command "onlick"!;P
-
My most recent, favourite subtle bug is:
foreach (string s in myStrings); { col.Add(s); }
and wondering why my collection never gets populated.But that should result in a compiler error because the variable
s
is not known outside the loop, shouldn't it? -
ok this is mine... I'm embarrassed to post this but here goes:
BtnSubmit.Attributes.Add("onlick", "disableSubmit()");
I'm wondering why on hell it's not disabling the button... when I suddenly spot my typo :doh: DOH! Somehow I don't think the button is going to be licked any time soon! :laugh:"For fifty bucks I'd put my face in their soup and blow." - George Costanza
~ Web SQL Utility - asp.net app to query Access, SQL server, MySQL. Stores history, favourites.
Ah, the joys of string based attribute programming, and the reason why people hate declarative programming--no compile time syntax checking! Marc
People are just notoriously impossible. --DavidCrow
There's NO excuse for not commenting your code. -- John Simmons / outlaw programmer
People who say that they will refactor their code later to make it "good" don't understand refactoring, nor the art and craft of programming. -- Josh Smith -
Alvaro Mendez wrote:
the problem is that if the user clicks the Stop button on the browser before the page comes back, the button stays disabled and he's stuck.
Stuck, like when you like a frozen railing kinda stuck?
cheers, Chris Maunder
CodeProject.com : C++ MVP
-
:laugh: Either that or lower my rates down to junior level :sigh:
"For fifty bucks I'd put my face in their soup and blow." - George Costanza
~ Web SQL Utility - asp.net app to query Access, SQL server, MySQL. Stores history, favourites.
Ashley van Gerven wrote:
:laugh: Either that or lower my rates down to junior level :sigh:
I'd go with the cheerleading if I were you, you might pick up a sugar daddy and never have to work again.
Michael Martin Australia "I controlled my laughter and simple said "No,I am very busy,so I can't write any code for you". The moment they heard this all the smiling face turned into a sad looking face and one of them farted. So I had to leave the place as soon as possible." - Mr.Prakash 24/04/2004
-
Alvaro Mendez wrote:
the problem is that if the user clicks the Stop button on the browser before the page comes back, the button stays disabled and he's stuck.
Stuck, like when you like a frozen railing kinda stuck?
cheers, Chris Maunder
CodeProject.com : C++ MVP
Chris Maunder wrote:
Stuck, like when you like a frozen railing kinda stuck?
For the second like do you really mean lick? It's people like (not lick) you that are an embarassment to Australia and it's spelling. Or at least to me, when I can no longer take the moral high ground over all them Yanks and Canucks thanks to you. The beer drinking was bad enough. You being capable of 1 has left people like me having to drink 13 (like tonight, when the missus told me it better be a quite one with me in bed early (does 02:45 count)) to keep the Aussie average up.
Michael Martin Australia "I controlled my laughter and simple said "No,I am very busy,so I can't write any code for you". The moment they heard this all the smiling face turned into a sad looking face and one of them farted. So I had to leave the place as soon as possible." - Mr.Prakash 24/04/2004
-
WTF Of The Day in coding, a WTF is a really obvious mistake, or really poor logic. I think this is the site that made the term famous: http://thedailywtf.com/[^]
"For fifty bucks I'd put my face in their soup and blow." - George Costanza
~ Web SQL Utility - asp.net app to query Access, SQL server, MySQL. Stores history, favourites.
That's the site-that-shall-not-be-linked. The guy who runs it has a poor opinion of the Code Project, and isn't shy about expressing it.
Software Zen:
delete this;
-
Chris Maunder wrote:
Stuck, like when you like a frozen railing kinda stuck?
For the second like do you really mean lick? It's people like (not lick) you that are an embarassment to Australia and it's spelling. Or at least to me, when I can no longer take the moral high ground over all them Yanks and Canucks thanks to you. The beer drinking was bad enough. You being capable of 1 has left people like me having to drink 13 (like tonight, when the missus told me it better be a quite one with me in bed early (does 02:45 count)) to keep the Aussie average up.
Michael Martin Australia "I controlled my laughter and simple said "No,I am very busy,so I can't write any code for you". The moment they heard this all the smiling face turned into a sad looking face and one of them farted. So I had to leave the place as soon as possible." - Mr.Prakash 24/04/2004
Michael Martin wrote:
it better be a quite one
When you say quite do you really mean quiet? Aaaahhh the irony ;P Reminds me of a Black Adder quote: Black Adder: Baldric, you do know what irony is don't you? Baldric: Yeah, it's like goldy and bronzy except made of iron :laugh:
"For fifty bucks I'd put my face in their soup and blow." - George Costanza
~ Web SQL Utility - asp.net app to query Access, SQL server, MySQL. Stores history, favourites.
-
That's the site-that-shall-not-be-linked. The guy who runs it has a poor opinion of the Code Project, and isn't shy about expressing it.
Software Zen:
delete this;
OK. Now you mention it I remember some controversy a few months ago about something on that site about CP.
"For fifty bucks I'd put my face in their soup and blow." - George Costanza
~ Web SQL Utility - asp.net app to query Access, SQL server, MySQL. Stores history, favourites.
-
Ah, the joys of string based attribute programming, and the reason why people hate declarative programming--no compile time syntax checking! Marc
People are just notoriously impossible. --DavidCrow
There's NO excuse for not commenting your code. -- John Simmons / outlaw programmer
People who say that they will refactor their code later to make it "good" don't understand refactoring, nor the art and craft of programming. -- Josh SmithEspecially database columns, which I'm sure many people have issues with - e.g.
row["fName"]
, which still compiles when someone renames the column to FirstName; which I sometimes avoid by doing this:row[db.Schema.FirstName]
."For fifty bucks I'd put my face in their soup and blow." - George Costanza
~ Web SQL Utility - asp.net app to query Access, SQL server, MySQL. Stores history, favourites.
-
OK. Now you mention it I remember some controversy a few months ago about something on that site about CP.
"For fifty bucks I'd put my face in their soup and blow." - George Costanza
~ Web SQL Utility - asp.net app to query Access, SQL server, MySQL. Stores history, favourites.
I like reading www.dailywtf.com every so often, but I did find Alex's comments ill-mannered.
Software Zen:
delete this;
-
Ashley van Gerven wrote:
Somehow I don't think the button is going to be licked any time soon!
Didn't Steve Jobs say, "We made the buttons look so good you would want to lick them"? So, the Mac has the command "onlick"!;P
Cool... so I'll leave my code intact, and all there is to do is eliminate every Windows PC from the world :sigh:
"For fifty bucks I'd put my face in their soup and blow." - George Costanza
~ Web SQL Utility - asp.net app to query Access, SQL server, MySQL. Stores history, favourites.
-
But that should result in a compiler error because the variable
s
is not known outside the loop, shouldn't it?Yes, I'm sorry my Firefox IDE didn't pick that up. Just an example anyway.
-
ok this is mine... I'm embarrassed to post this but here goes:
BtnSubmit.Attributes.Add("onlick", "disableSubmit()");
I'm wondering why on hell it's not disabling the button... when I suddenly spot my typo :doh: DOH! Somehow I don't think the button is going to be licked any time soon! :laugh:"For fifty bucks I'd put my face in their soup and blow." - George Costanza
~ Web SQL Utility - asp.net app to query Access, SQL server, MySQL. Stores history, favourites.
:-D :thumbsup: