• ChrisE (unregistered) in reply to Neil
    Neil:
    I thought HTML was the underpinning of the web and Javascript was a bloated tumor hanging off the side.

    Yes, if you live in the 90s. Welcome to technology!

  • Sasha Nein (unregistered)

    Oh... so tacky! Can't... look... directly at it!

  • ih8u (unregistered) in reply to Kef Schecter
    Kef Schecter:
    Anonymous:
    How can anyone write out the script block (<SCRIPT LANGUAGE='JavaScript'>) without realising that they're emitting Javascript?

    I doubt that was actually the case. The point was to carry the operation out from the server side, which was what happened. Yes, that doesn't literally comply with Sascha's command to "do it without JavaScript", but it complies with the spirit in which it was intended: the server side initiating what's normally client-side behavior.

    • Kef

    Kef, you and the coworker might get along well boss. He loves AJAX and wants to use it as much as possible. He, however, HATES javascript and never wants to hear that it is in ANY of our projects.

    So I tell him, "I used AJAX to make that function work" and never happen to mention what the J stands for.

    Just like you and coworker -- call it something different and it's magically different.

  • Jay (unregistered)

    How about this method of closing a browser window without Javascript:

    out.println("

    Please call the help desk at extension 555 and ask them to send someone over to close your browser window.

    ");

    Or method #2:

    out.println("

    Prepareing to download 60 GB of child pornography."); out.println("

    Confirmation emails will be sent to you, your boss, and your wife once download begins."); out.println("

    Click OK to continue or close this browser window to terminate operation.");

  • Mike (unregistered)

    If your users are using IE6, you don't need javascript to close the window, just plain HTML!!

    <style>*{position:relative}</style><input>
  • An Onymous (unregistered)

    Easy:

    <SCRIPT LANGUAGE='JScript'>
    <!--
    window.close();
    //-->
    </SCRIPT>

    ... there you go. No JavaScript to be found anywhere.

  • IV (unregistered)

    I like my women like I like my security - nonexistent. Wait, that's not what I like; it's just what I'm used to. I have got to find better schools.

  • @Deprecated (unregistered)

    Instead of closing the browser, you could always just send a picture of the default Windows desktop.

    Then the user will call their help desk, complaining that none of their icons work anymore.

  • coffee (unregistered) in reply to ACDC
    I like my coffee like I like my men - strong and black

    I like Turkish coffee...

  • (cs) in reply to Not THAT Alex
    Not THAT Alex:
    Konrads:
    Actually,

    It can work: Have a COMET/AJAX connection open to server and have server send the message at will.

    Do you know what the "J" in AJAX stands for? I'm guessing the answer is no.

    Thank you.
  • (cs) in reply to An Onymous
    An Onymous:
    Easy:
    <SCRIPT LANGUAGE='JScript'>
    <!--
    window.close();
    //-->
    </SCRIPT>

    ... there you go. No JavaScript to be found anywhere.

    Again, this doesn't close a Web browser window -- only Windows Explorer windows when they happen to be viewing a Web page.

    But you do realize, don't you, that "JScript" is just the Microsoft implementation of ECMAscript; which is what most people mean when they say "Javascript"?

    Addendum (2009-07-27 13:31):

    An Onymous:
    Easy:
    <SCRIPT LANGUAGE='JScript'>
    <!--
    window.close();
    //-->
    </SCRIPT>

    ... there you go. No JavaScript to be found anywhere.

    Again, this doesn't close a Web browser window -- only Windows Explorer windows when they happen to be viewing a Web page.

    But you do realize, don't you, that "JScript" is just the Microsoft implementation of ECMAscript; which is what most people mean when they say "Javascript"?

    In fact, let's just go a little further with your snarky challenge... When you say "No JavaScript to be found anywhere.", actually, because it's a function in the ECMAscript minimum specification, that function is to be found in any implementation of ECMAscript. Which means that, because it can be found in both JScript and Javascript, then the Javascript function can be said to be found in JScript, and weaker worser.

    So yeah, you're wrong on many levels.

  • (cs) in reply to nonny nonny
    nonny nonny:
    ACDC:
    I like my coffee like I like my men - strong and black
    I like my coffee sweet and creamy...
    My coffee/women: hot, creamy, rich, tasty, and with a delightfully heady aroma.
  • (cs) in reply to Not THAT Alex
    Not THAT Alex:
    Do you know what the "J" in AJAX stands for? I'm guessing the answer is no.

    Apparently, neither do you.

    (For the lazy: Ajax's creator didn't intend it to be an acronym, simply a name for the technology; other people subsequently prodded the name with sticks it until it became a suitable acronym.)

  • Billy (unregistered)

    Typical of a workplace. Two brace-faced pre-teens wasting time arguing over what is server side code, when really what does it matter to a client? They asked for the window to close sheesh...

  • Doug R (unregistered)

    Reminds me of when a client once wanted me to implement an embedded audio player in javascript ONLY, no Flash.

    Me: This can't be done. (This is pre HTML5)

    Client: Yes it can. Just look at this code.

    code is a javascript block instantiating a new SWFObject...

  • dominic (unregistered) in reply to rfsmit
    rfsmit:
    An Onymous:
    Easy:
    <SCRIPT LANGUAGE='JScript'>
    <!--
    window.close();
    //-->
    </SCRIPT>

    ... there you go. No JavaScript to be found anywhere.

    Again, this doesn't close a Web browser window -- only Windows Explorer windows when they happen to be viewing a Web page.

    But you do realize, don't you, that "JScript" is just the Microsoft implementation of ECMAscript; which is what most people mean when they say "Javascript"?

    Addendum (2009-07-27 13:31):

    An Onymous:
    Easy:
    <SCRIPT LANGUAGE='JScript'>
    <!--
    window.close();
    //-->
    </SCRIPT>

    ... there you go. No JavaScript to be found anywhere.

    Again, this doesn't close a Web browser window -- only Windows Explorer windows when they happen to be viewing a Web page.

    But you do realize, don't you, that "JScript" is just the Microsoft implementation of ECMAscript; which is what most people mean when they say "Javascript"?

    In fact, let's just go a little further with your snarky challenge... When you say "No JavaScript to be found anywhere.", actually, because it's a function in the ECMAscript minimum specification, that function is to be found in any implementation of ECMAscript. Which means that, because it can be found in both JScript and Javascript, then the Javascript function can be said to be found in JScript, and weaker worser.

    So yeah, you're wrong on many levels.

    Ah, but, it is in fact you who is wrong on so many levels! Let me count the ways:

    Internet Explorer is a separate entity to Windows Explorer now - so in fact it is a web browser interpreting the code.

    It is true that most people mean ECMAScript when they say JavaScript, but that is not the point. The point is to be technically correct (the best kind of correct)

    window.close isn't a function in the ECMAScript minimum specification. In fact you won't find a definition of window anywhere in ECMAScript, especially not window.close, save for a reference to - are you ready for this - the DOM! A completely separate specification to ECMAScript. Did you know you can implement the DOM in any language you choose? Anyway, that means that the function will not be found in any implementation of ECMAScript. For example, any non-browser application using spidermonkey for scripting, while being a perfectly valid implementation of ECMAScript, will have neither hide nor hair of a window object (at least not one you are expecting)

    It's often a good idea to do research before you post things like this! It's okay, I'll let you off this time...

  • monkeyPushButton (unregistered) in reply to coffee
    coffee:
    I like my coffee like I like my men - strong and black
    I like Turkish coffee...
    Irish (Girl) coffee anyone?

    CAPTCHA: eros (need anything more be said?)

  • Anonymous Coward (unregistered) in reply to Heron
    Heron:
    Not THAT Alex:
    Do you know what the "J" in AJAX stands for? I'm guessing the answer is no.

    Apparently, neither do you.

    (For the lazy: Ajax's creator didn't intend it to be an acronym, simply a name for the technology; other people subsequently prodded the name with sticks it until it became a suitable acronym.)

    For the lazy & ignorant, the line cited is a casual note saying "At subsequent talks and seminars Garrett has made the point that Ajax is not an acronym."

    It is not properly cited, and even if it is true that they make such a point in seminars, it doesn't mean that it must be true. This is a common technique attempted with trademarked concepts, for example, gaim.

    Besides, why would you name a tool like this ajax? Without an acronym, that's a horrible name! The article claims it was concieved of in the shower while trying to figure out a shorthand name to refer to a suite of programs including Javascript.

  • Techpaul (unregistered) in reply to Code Dependent

    Most men simply like their women BREATHING!

    As in the old adage

    For men to get laid they have to

    "carress, carouse, cajole........."

    For women to get laid

    "Turn up naked!"

  • Yes THAT Ben (unregistered) in reply to Not THAT Alex
    Not THAT Alex:
    Konrads:
    Actually,

    It can work: Have a COMET/AJAX connection open to server and have server send the message at will.

    Do you know what the "J" in AJAX stands for? I'm guessing the answer is no.

    In that case, why don't we give the user a message that asks them to download a rootkit so the server can shut their computer down. There, no JavaScript!
  • wgc (unregistered) in reply to Procedural
    Procedural:
    I prefer tall, smart and sweet. With long legs, full lips, sparkly eyes, an adventurous spirit and long long hair.

    I think I had coffee at that same diner once, after a bottle of tequila. That's why the kitchen staff usually have to wear nets.

  • Bernie (unregistered)

    I like my women like I like my favorite color: Blue. No yel-- auuuuuuuugh!

  • (cs) in reply to Billy
    Billy:
    Typical of a workplace. Two brace-faced pre-teens wasting time arguing over what is server side code, when really what does it matter to a client? They asked for the window to close sheesh...
    "Well," Sascha said, "congratulations."
    Doesn't seem like much of an argument.
  • mvp (unregistered)

    Real WTF is that window.close() call in emitted string is actually commented out. So this procedure wouldn't work :-)

  • Jimmy the Geek (unregistered)

    What is the big deal about needing client side scripting to close a window? Without some kind of scripting how would the client know when it was time to close the window?

  • SwedishChef (unregistered) in reply to rfsmit
    rfsmit:
    An Onymous:
    Easy:
    <SCRIPT LANGUAGE='JScript'>
    <!--
    window.close();
    //-->
    </SCRIPT>

    ... there you go. No JavaScript to be found anywhere.

    Again, this doesn't close a Web browser window -- only Windows Explorer windows when they happen to be viewing a Web page.

    But you do realize, don't you, that "JScript" is just the Microsoft implementation of ECMAscript; which is what most people mean when they say "Javascript"?

    Addendum (2009-07-27 13:31):

    An Onymous:
    Easy:
    <SCRIPT LANGUAGE='JScript'>
    <!--
    window.close();
    //-->
    </SCRIPT>

    ... there you go. No JavaScript to be found anywhere.

    Again, this doesn't close a Web browser window -- only Windows Explorer windows when they happen to be viewing a Web page.

    But you do realize, don't you, that "JScript" is just the Microsoft implementation of ECMAscript; which is what most people mean when they say "Javascript"?

    In fact, let's just go a little further with your snarky challenge... When you say "No JavaScript to be found anywhere.", actually, because it's a function in the ECMAscript minimum specification, that function is to be found in any implementation of ECMAscript. Which means that, because it can be found in both JScript and Javascript, then the Javascript function can be said to be found in JScript, and weaker worser.

    So yeah, you're wrong on many levels.

    Wow. WHOOOOOOOOOOSHHHHH - in formation, mind you

  • (cs) in reply to Techpaul
    Techpaul:
    Most men simply like their women BREATHING!

    As in the old adage

    For men to get laid they have to

    "carress, carouse, cajole........."

    For women to get laid

    "Turn up naked!"

    Surely you mean "Turn up!"
  • Michael Vick (unregistered)

    I like my coffee like I like my women: black, thick, and wet.

  • whatevs (unregistered) in reply to AdT

    A TROLL! A TROLL! KILL IT!

  • maharaj (unregistered) in reply to nerfherder
    nerfherder:
    Rootbeer:
    This was actually not as bad as I had feared. I clicked the cut-text entirely expecting to find some server-side code that triggers a code exploit in the browser, causing it to crash. If the browser dies, then the window ends up closing, right?

    That wouldn't be a WTF, that would be a novel solution.

    novel or Novell?

  • Nat (unregistered) in reply to nonny nonny
    nonny nonny:
    ACDC:
    I like my coffee like I like my men - strong and black

    I like my coffee sweet and creamy...

    ...Like you like your women?

  • Jo (unregistered) in reply to Jay
    Jay:
    How about this method of closing a browser window without Javascript:

    out.println("

    Please call the help desk at extension 555 and ask them to send someone over to close your browser window.

    ");

    Or method #2:

    out.println("

    Prepareing to download 60 GB of child pornography."); out.println("

    Confirmation emails will be sent to you, your boss, and your wife once download begins."); out.println("

    Click OK to continue or close this browser window to terminate operation.");

    Nice!!!!

    Reading Method two, I figured line 1 would work for most people...And I doubt you need line 3, cos if line 1 didn't frighten them off, line two almost certainly should

  • Mlit (unregistered) in reply to Anonymous Coward
    Anonymous Coward:
    Heron:
    Not THAT Alex:
    Do you know what the "J" in AJAX stands for? I'm guessing the answer is no.

    Apparently, neither do you.

    (For the lazy: Ajax's creator didn't intend it to be an acronym, simply a name for the technology; other people subsequently prodded the name with sticks it until it became a suitable acronym.)

    For the lazy & ignorant, the line cited is a casual note saying "At subsequent talks and seminars Garrett has made the point that Ajax is not an acronym."

    It is not properly cited, and even if it is true that they make such a point in seminars, it doesn't mean that it must be true. This is a common technique attempted with trademarked concepts, for example, gaim.

    Besides, why would you name a tool like this ajax? Without an acronym, that's a horrible name! The article claims it was concieved of in the shower while trying to figure out a shorthand name to refer to a suite of programs including Javascript.

    a) Wikipedia is never wrong b) I can see why he would think of AJAX in the shower - isn't it a bathroom cleaner?

  • Some Male Feminist (unregistered)

    I like my women self-defined. She defines her own strong points and my reason to interact with her is self-evident. However, it does not follow that she has reason to interact with me; that part is up to me.

    Or, to dumb it way down:

    Treat women as people, and if you want to define someone, start with yourself.

  • Shinobu (unregistered)

    Okay, I don't believe for a second that the cow-orker believes that he isn't using JS, so I think the conversation was faked. I don't know what the original conversation was like exactly, but I think along the lines of Sasha didn't understand that you could initiate client-side behaviour remotely in any way, and because he thought he knew why, it was useless talking to him and he had to be shown an example, putting him in his place. Then his ego was hurt and he complains about it here.

  • (cs) in reply to Some Male Feminist
    Some Male Feminist:
    I like my women self-defined. She defines her own strong points and my reason to interact with her is self-evident. However, it does not follow that she has reason to interact with me; that part is up to me.

    Or, to dumb it way down:

    Treat women as people, and if you want to define someone, start with yourself.

    Is she as humorless as you?

  • Alexandre Brault (unregistered) in reply to mvp
    mvp:
    Real WTF is that window.close() call in emitted string is actually commented out. So this procedure wouldn't work :-)
    That line isn't commented out. The code writes the following to the webpage:
    <SCRIPT LANGUAGE='JavaScript'> <!-- window.close(); //--> </SCRIPT>
    Barring the non-existent 'LANGUAGE' attribute and the missing 'type' (and the all-caps for the tag name for XHTML), this is valid HTML

    Captcha: genitus. Genius genitals?

  • Anonymous (unregistered) in reply to Mlit
    Mlit:
    a) Wikipedia is never wrong
    Thanks, I needed a laugh!
  • JohnFx (unregistered)

    Actually, it is COMPLETELY possible* to shut down the browser with just server side code!

    • Void when user is not accessing the site from a browser on the web server.
  • ClaudeSuck.de (unregistered) in reply to ACDC
    ACDC:
    I like my coffee like I like my men - strong and black

    I like my strong and black...

  • titter.com (unregistered) in reply to Some Male Feminist
    Some Male Feminist:
    I like my women self-defined. She defines her own strong points and my reason to interact with her is self-evident. However, it does not follow that she has reason to interact with me; that part is up to me.

    Or, to dumb it way down:

    Treat women as people, and if you want to define someone, start with yourself.

    Your life must be wonderfully blank and mediocre.

    Just the way I like my A4 sheets.

  • BeanDur (unregistered) in reply to An Onymous

    Please validate (validator.w3) all your code to STRICT.

    If any of your tags or attribute keys are uppercase, or they aren't closed, you FAIL.

    If you are using inline CSS, you FAIL.

    If you can't figure out how to pass validation, please apply for promotion to management.

    Thank you.

  • ClaudeSuck.de (unregistered) in reply to Yes THAT Ben
    Yes THAT Ben:
    Not THAT Alex:
    Konrads:
    Actually,

    It can work: Have a COMET/AJAX connection open to server and have server send the message at will.

    Do you know what the "J" in AJAX stands for? I'm guessing the answer is no.

    In that case, why don't we give the user a message that asks them to download a rootkit so the server can shut their computer down. There, no JavaScript!

    sendkeys "copy con rundll32 user,ExitWindows 1 CTRL-Z > start.bat start"

    a little debugging and it should work, too.

  • ClaudeSuck.de (unregistered) in reply to BeanDur
    BeanDur:
    Please validate (validator.w3) all your code to STRICT.

    If any of your tags or attribute keys are uppercase, or they aren't closed, you FAIL.

    If you are using inline CSS, you FAIL.

    If you can't figure out how to pass validation, please apply for promotion to management.

    Thank you.

    Why would I want to fail all the time?

  • Joel (unregistered) in reply to Some Male Feminist
    Some Male Feminist:
    I like my women self-defined. She defines her own strong points and my reason to interact with her is self-evident. However, it does not follow that she has reason to interact with me; that part is up to me.

    Or, to dumb it way down:

    Treat women as people, and if you want to define someone, start with yourself.

    interesting: - the first comment was 'I like my coffee like I like my men....etc' (presumably by a woman) - the first 'Oh Grow up and don't objectify people' post comes against the (presumably) men who continued the original thread.

    Typical <roll eyes>

  • Jason (unregistered) in reply to Joel
    Joel:
    Some Male Feminist:
    I like my women self-defined. She defines her own strong points and my reason to interact with her is self-evident. However, it does not follow that she has reason to interact with me; that part is up to me.

    Or, to dumb it way down:

    Treat women as people, and if you want to define someone, start with yourself.

    interesting: - the first comment was 'I like my coffee like I like my men....etc' (presumably by a woman) - the first 'Oh Grow up and don't objectify people' post comes against the (presumably) men who continued the original thread.

    Typical <roll eyes>

    And by a bloke who probably thinks he's a SNAG, seeing as he clearly knows what women want!!

    Captcha: Haero....what a coincidence...

  • Xythar (unregistered)

    I honestly didn't realise that people still programmed in Visual Basic in the "real world". Is there reason to? The last time I used Visual Basic was in high school.

  • Procedural (unregistered) in reply to Some Male Feminist
    Some Male Feminist:
    I like my women self-defined. She defines her own strong points and my reason to interact with her is self-evident. However, it does not follow that she has reason to interact with me; that part is up to me.

    Or, to dumb it way down:

    Treat women as people, and if you want to define someone, start with yourself.

    Ah, a male feminist. I admire your desire to fraternize with the enemy in the battle of the sexes, but some of us prefer actual engagement.

  • Procedural (unregistered) in reply to Xythar
    Xythar:
    I honestly didn't realise that people still programmed in Visual Basic in the "real world". Is there reason to? The last time I used Visual Basic was in high school.

    Not really; unless the guy who cuts the cheques really really wants you to and is unwilling to consider better/any alternatives.

  • acid (unregistered)

    I pretty much only read TDWTF for the comments these days - today I wasn't disappointed. Oh, and I don't drink coffee anymore (although I love it) because the caffeine keeps me awake, nervous and dehydrated...

    Like some women that have been in my life before...

    But I digress.

    These days I stick to ginger herbal tea. Good for you, warming and with just a hint of spice.

    Oh, and ginger herbal tea doesn't contain ANY javascript or any other variation thereof, nor does it require IE or any other browser or non-browser or pseudo-browser to run. Stangely enough though, pouring a cup of it over the motherboard would pretty much close the window in question, whether the server meant to do it or not...

    Food for thought.

Leave a comment on “What Fundamental Underpinning?”

Log In or post as a guest

Replying to comment #:

« Return to Article