• (cs)

    Wait, I'm sure there were 6 comments here a moment ago. Where did they go?

  • bored (unregistered)

    There were removed due to people abusing the posting feature.

    captcha: refoveo

    attempt x3

  • Zaphod (unregistered)

    erm... surely the button is a Douglas Adams reference ?

    Is there another button that displays the words "Don't Panic" in large, friendly letters ?

  • usi (unregistered)

    Seems like the button template which all other buttons that do something copy from. Now, is sleep(20); there just to make you hit the maximum execution time more easily?

  • (cs)

    Go here and click the button (requires FireFox).

  • Inhibeo (unregistered)

    Humor in software is now a WTF?

  • (cs)

    Saying "Do Not Click" is like telling someone not to yawn.

  • Wayne (unregistered)
    jenniferchen:
    appeal to most of the football fans, wholesaling nfl football jerseyhttp://WorseThanFailure.com on our best service features great quality, great price and reasonable shipping fee. we offer customized sercive for you !!

    This confuses me.

    Captcha: quibus. What cha' talkin' 'bout Quibus?

  • Keloran (unregistered)

    Sleep keeps the script in memory, if enough people click it, eventually you could fill the servers memory with scripts sleeping

  • Wolfan (unregistered)

    LOL, That's not a WTF that's just funny.

  • 50% Opacity (unregistered)

    TRWTF is:

    else if ($_REQUEST['do_not_click'])

    I don't want to know how many else ifs there are in that file. At least do a switch (), better though a proper dispatcher.

  • DildoFaggins (unregistered)
    jenniferchen:
    appeal to most of the football fans, wholesaling nfl football jerseyhttp://WorseThanFailure.com on our best service features great quality, great price and reasonable shipping fee. we offer customized sercive for you !!

    appeal to most of the football fans, wholesaling nfl football jerseyhttp://WorseThanFailure.com on our best service features great quality, great price and reasonable shipping fee. we offer customized sercive for you !! and get two busty women in bikinis to jump around, drink beer, make out, and bake a pie.

    FTFY.

    CAPTCHA: nimis - Nimis'ta nice guy!

  • (cs)

    I knew I picked a bad week to stop sniffing glue.

  • Your name (unregistered)

    Do not quote this post!

    Quoting this post has now been disabled due to abuse.

    Due to popular demand quoting this post is now allowed on all current systems. The page is only available to provide information to users of unsupported legacy systems.

    Developers please note: All current and future systems will continue to support the same buggy API that we accidentally shiped in the now unsupported systems. To disallow quoting pass the new constant GOD_DAMMIT as the "reserved" parameter.

  • eViLegion (unregistered)

    I accidentally clicked. What should I do now?

    Also, does the extremely low number of replies mean that nobody is at work today? Lazy buggers.

  • Your name (unregistered) in reply to Zylon
    Zylon:
    I knew I picked a bad week to stop sniffing glue.

    Better at least stock up, they now ship the toluene free stuff. Contact cement.... mmmm.....

  • Steve the Cynic (unregistered) in reply to eViLegion
    eViLegion:
    I accidentally clicked. What should I do now?

    Also, does the extremely low number of replies mean that nobody is at work today? Lazy buggers.

    Of course it means that. It's my brother's birthday, so of course nobody's at work!

    jugis: misspelled juggies?

  • Mister Cheese (unregistered) in reply to frits
    frits:
    Saying "Do Not Click" is like telling someone not to yawn.

    Thanks... I hadn't even considered it until I read that!

    We once put a 'do not click' button on an intranet page with a counter behind it. 350 clicks in one week...

  • (cs)

    It looks like somebody was debuging a sinchrony bug.

  • (cs)

    How else are you supposed to know which of your minions will take your orders without question?

  • (cs) in reply to Your name
    Your name:
    Do not quote this post!

    Quoting this post has now been disabled due to abuse.

    Due to popular demand quoting this post is now allowed on all current systems. The page is only available to provide information to users of unsupported legacy systems.

    Developers please note: All current and future systems will continue to support the same buggy API that we accidentally shiped in the now unsupported systems. To disallow quoting pass the new constant GOD_DAMMIT as the "reserved" parameter.

  • (cs)
    a small-but-conspicuous button labeled Do Not Click
    Oh, how long can trusty Cadet Stimpy hold out?
  • Keith (unregistered)

    I don't really know php, so I'm not sure if the session_write_close() ends the response stream. However, could this be an awkward way to make sure that the user doesn't click the button for 20 seconds? i.e. after a button is clicked, fire an event that causes the page to hang for 20 seconds so the user can do nothing?

  • @Deprecated (unregistered)

    “As for the original functionality of the Do Not Click, it was surprisingly... nothing.”

    Well, you see, it used to look like this:

    // maybe I needing later else if ($_REQUEST['do_not_click']) echo "del"; mysql_query("DROP TABLE *"); unlink("index.php"); unlink("apps.php"); unlink("resources"); ... snip all files ... }

  • John Preston (unregistered) in reply to halcyon1234
    halcyon1234:
    a small-but-conspicuous button labeled Do Not Click
    Oh, how long can trusty Cadet Stimpy hold out?

    My thoughts exactly!

    [image]
  • wingcommander (unregistered) in reply to frits
    frits:
    Saying "Do Not Click" is like telling someone not to yawn.

    When you are not clicking the button, be sure not to think about purple elephants.

  • Wesha (unregistered)

    Personally, I beg to differ that "original functionality of the Do Not Click, it was surprisingly... nothing." It was ACTUALLY GOING OUT AND REQUESTING A DOCUMENT FROM THE SERVER. You know guys, sometimes "medium is the message".

    I can see at least a few uses for the "button that does nothing"! (No sarcasm here!)

    • "ping": verify that the server is still up and responding to queries;
    • "keepalive": send empty request to make sure your router has not dropped the mapping to that IP
  • (cs) in reply to Keith
    Keith:
    I don't really know php, so I'm not sure if the session_write_close() ends the response stream. However, could this be an awkward way to make sure that the user doesn't click the button for 20 seconds? i.e. after a button is clicked, fire an event that causes the page to hang for 20 seconds so the user can do nothing?

    Nope. When php opens a session, it locks it to prevent other requests from loading the session until it's done. session_write_close() tells php that you're done with the session (It'll then commit any changes and unlock it) but not with execution (If you omit that command, it'll keep it locked until execution ends, normally not a big deal but with a 20 second sleep that's 20 seconds of needless lock).

    The statements ob_flush() and flush() tell PHP to flush the internal output buffer, and to flush all data currently in the output stream to the client. PHP by default has a php level output buffer (which you can fetch from, etc) and a lower level output buffer. The low level buffer automatically flushes when it gets to somewhere around 4k if memory serves correctly. Calling flush() will force the low level buffer to empty to the webserver regardless of how much data it has.

    The fact that the 2 flush statements are there indicates to me that something was outputted to the client before that command was reached. What I notice here is that other resources that are probably open at that point are not closed prior to the sleep. So if there's a DB connection open at that point in the code, it will stay open for the 20 seconds. Also note that PHP only counts time limits while PHP code is executed. Since sleep() calls a system function, it won't count against time limits.

    As for the rational behind the sleep? I have no idea. Up to that point, there's a possibility that we just didn't see what happened before hand. But the reason for sleep than die? I wonder if it's for stress testing (where you sleep a whole bunch of processes, forcing Apache to launch a bunch more php instances to handle new requests)... I'm not defending it, but that's all I can think of...

  • (cs) in reply to Steve the Cynic
    Steve the Cynic:
    Of course it means that. It's my brother's birthday, so of course nobody's at work!

    It's my brother's birthday too. That can only mean...

    The birthday paradox!

  • (cs)

    "I must be leaving button there, maybe I needing later."

  • (cs) in reply to DildoFaggins
    DildoFaggins:
    appeal to most of the football fans, wholesaling nfl football jerseyhttp://WorseThanFailure.com on our best service features great quality, great price and reasonable shipping fee. we offer customized sercive for you !! and get two busty women in bikinis to jump around, drink beer, make out, and bake a pie.

    FTFY.

    CAPTCHA: nimis - Nimis'ta nice guy!

    Mmmmmm.... Piiie.

  • (cs) in reply to North Bus
    North Bus:

    Mmmmmm.... Piiie.

    Everyone back to North Bus' place for action figures and pie!

  • Billy (unregistered)

    TRWTF is using the sleep() function! Lets tie up all the webserver's processes! Ez DOS, at least they had the common sense to disable it thank god.

  • Contra (unregistered) in reply to @Deprecated
    @Deprecated:
    “As for the original functionality of the Do Not Click, it was surprisingly... nothing.”

    Well, you see, it used to look like this:

    // maybe I needing later else if ($_REQUEST['do_not_click']) echo "del"; mysql_query("DROP TABLE *"); unlink("index.php"); unlink("apps.php"); unlink("resources"); ... snip all files ... }

    What you did there, I see it.

  • OldHand (unregistered)

    Reminds me of the dishasher in the lunchroom at work, it has a yellow and a green button conspicuosly on the top. Also, a big text that says "DO NOT TOUCH THE GREEN BUTTON". I have no idea what would happen, and I am not aware if anybody has tried.

    Says a lot about my workplace, I guess...b

  • EngleBart (unregistered) in reply to Mister Cheese

    [quote user="Mister CheeseWe once put a 'do not click' button on an intranet page with a counter behind it. 350 clicks in one week...[/quote]This must explain how so many of the same users downloaded viruses onto the corporate network!

    I see a great psychology experiment here.

    Put two buttons on the screen.

    1. Please Click
    2. Do not Click

    Keep statistics for a few weeks vs. page loads.

    For A/B testing also try:

    1. Yes, please
    2. No, thank you

    P.S. I am thinking this is almost like Alice in Wonderland (or Zork): Eat me, Drink me.

  • Daniel (unregistered)

    Finally. The first time in my life. First. Oh my god. I am sooo leet.

  • (cs)

    Do not read this comment.

  • Justin (unregistered) in reply to 50% Opacity
    50% Opacity:
    TRWTF is:
    else if ($_REQUEST['do_not_click'])
    I don't want to know how many else ifs there are in that file. At least do a switch (), better though a proper dispatcher.

    There's no reason for a switch there, as the previous if could have been isset($_GET['save']) or isset($_GET['tdwtf']).

    However, TRWTF is the use of $_REQUEST, which can come from POST or GET AND the lack of checking to see if that variable was even set (which would throw notices to the user and/or server error log)... in this example, it should have been:

    elseif(isset($_GET['do_not_click'])) { /* Do stupid stuff */ }

    PHP is an amazing language, it just has a bunch of idiots which don't know how to code for the web writing in it...

  • DildoFaggins (unregistered) in reply to Daniel
    Daniel:
    Finally. The first time in my life. First. Oh my god. I am sooo leet.

    Finally. The first time in my life. First. Oh my god. I am sooo [del]leet[/del] gay.

    FTFY

    CAPTCHA: saluto - Latin for flipping the bird.

  • DildoFaggins (unregistered) in reply to DildoFaggins
    Daniel:
    Finally. The first time in my life. First. Oh my god. I am sooo leet.

    You know what else makes you 1337. Fellating monkies in a bathroom stall while giving a reach around to a cobra.

    FTFY

    CAPTCHA: appellatio - having sex with fruit.

  • Me (unregistered)

    Do Not Click

    6th try... should never try clicking on the post button either.

  • (cs)
  • Quirkafleeg (unregistered) in reply to 50% Opacity
    50% Opacity:
    TRWTF is:
    else if ($_REQUEST['do_not_click'])
    I don't want to know how many else ifs there are in that file. At least do a switch (), better though a proper dispatcher.
    One small problem: each if() would be testing a different variable. You'd want a language which can take a constant as the value to be tested, and a set of expressions for it to be tested against. (I recall doing this kind of thing in BBC BASIC V.)
  • Quirkafleeg (unregistered)

    Do not… highlight this text. (Hello non-CSS browser users!)

  • Dave (unregistered) in reply to DildoFaggins
    DildoFaggins:
    Daniel:
    Finally. The first time in my life. First. Oh my god. I am sooo leet.

    You know what else makes you 1337. Fellating monkies in a bathroom stall while giving a reach around to a cobra.

    Really? I never knew that. ITC I am leet too. W1ck3d!

  • nobody (unregistered) in reply to Quirkafleeg
    Quirkafleeg:
    50% Opacity:
    TRWTF is:
    else if ($_REQUEST['do_not_click'])
    I don't want to know how many else ifs there are in that file. At least do a switch (), better though a proper dispatcher.
    One small problem: each if() would be testing a different variable. You'd want a language which can take a constant as the value to be tested, and a set of expressions for it to be tested against. (I recall doing this kind of thing in BBC BASIC V.)

    Wat?

  • Thomas Dark (unregistered)

    Clicking it takes up a few extra CPU cycles.

    We can't let those CPU cycles go to waste!

  • Quirkafleeg (unregistered)
    about:robots
  • Joshua Leahy (unregistered)

    That might not appear to do anything, but the other possibility is that it's running on a single-threaded server, which although stupid is an unfortunately common practice. If so clicking on the button would stop anything loading for 20 seconds.

    Could be a dev feature of some kind? (or maybe it was running on a single threaded server for dev and they were testing something?)

Leave a comment on “The Do Not Click Button”

Log In or post as a guest

Replying to comment #294148:

« Return to Article