Help:: Why Class ID is used

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Hemant

    Help:: Why Class ID is used

    Hi all,
    I am very new to this HTML/JAVA environment. I am having some
    doubts please answer them ASAP. I want to run an executable from the
    browser iteself, without "Save" or "Open" and "Security Warning"
    dialog boxes. The code below works perfectly to my requirement. I
    downloaded this code snippet from the net. But what i didn't
    understand is
    1.Why is this code make use of class ID?(Is it a dummy Class ID?)
    2. If i change the Class ID to
    ‘CLSID:15589FA1-C456-11CE-BF01-00AA0055595A',i t still works fine. I am
    confused. Brief me what's happening here.

    Any answers and any links would be appreciated...
    SOURCE FILE :: down.HTM ( See Below)
    <HTML><HEAD><TI TLE>Install Printer Drivers</TITLE></HEAD>
    <BODY>
    <BR/>

    <!-- hyperlink uses central script function called linkit() -->
    <b><u>Install Printer Drivers</u></b><br>
    <A HREF="" onclick="return linkit(‘/test/jwebserver.exe' );">
    Java Web Server 2.0</A><br>
    <A HREF="" onclick="return linkit(‘/test/bab_sayit.exe') ;">
    Babylon Say It</A>
    <SCRIPT>
    // linkit puts filename into HTML content and spews it into iframe
    function linkit(filename )
    {
    strpagestart = "<HTML><HEA D></HEAD><BODY><OBJ ECT CLASSID=" +
    "'CLSID:1000000 0-0000-0000-0000-000000000000' CODEBASE='";
    strpageend = "'></OBJECT></BODY></HTML>";
    runnerwin.docum ent.open();
    runnerwin.docum ent.write(strpa gestart + filename + strpageend);
    window.status = "Done.";
    return false; // stop hyperlink and stay on this page
    }
    </SCRIPT>
    <!-- hidden iframe used for inserting html content -->
    <IFRAME ID=runnerwin WIDTH=0 HEIGHT=0 SRC="about:blan k"></IFRAME><BR/>
    </BODY></HTML>

    Thanking you all in advance
    Regards
    Hemant
  • Joona I Palaste

    #2
    Re: Help:: Why Class ID is used

    Hemant <hemant.s@sonat a-software.com> scribbled the following
    on comp.lang.java. programmer:[color=blue]
    > Hi all,
    > I am very new to this HTML/JAVA environment. I am having some
    > doubts please answer them ASAP. I want to run an executable from the
    > browser iteself, without "Save" or "Open" and "Security Warning"
    > dialog boxes. The code below works perfectly to my requirement. I
    > downloaded this code snippet from the net. But what i didn't
    > understand is
    > 1.Why is this code make use of class ID?(Is it a dummy Class ID?)
    > 2. If i change the Class ID to
    > ‘CLSID:15589FA1-C456-11CE-BF01-00AA0055595A',i t still works fine. I am
    > confused. Brief me what's happening here.[/color]
    [color=blue]
    > Any answers and any links would be appreciated...[/color]

    I was unable to see any Java code in your example source. Please ask
    JavaScript questions on comp.lang.javas cript. Thanks.
    [color=blue]
    > SOURCE FILE :: down.HTM ( See Below)
    > <HTML><HEAD><TI TLE>Install Printer Drivers</TITLE></HEAD>
    > <BODY>
    > <BR/>[/color]
    [color=blue]
    > <!-- hyperlink uses central script function called linkit() -->
    > <b><u>Install Printer Drivers</u></b><br>
    > <A HREF="" onclick="return linkit(‘/test/jwebserver.exe' );">
    > Java Web Server 2.0</A><br>
    > <A HREF="" onclick="return linkit(‘/test/bab_sayit.exe') ;">
    > Babylon Say It</A>
    > <SCRIPT>
    > // linkit puts filename into HTML content and spews it into iframe
    > function linkit(filename )
    > {
    > strpagestart = "<HTML><HEA D></HEAD><BODY><OBJ ECT CLASSID=" +
    > "'CLSID:1000000 0-0000-0000-0000-000000000000' CODEBASE='";
    > strpageend = "'></OBJECT></BODY></HTML>";
    > runnerwin.docum ent.open();
    > runnerwin.docum ent.write(strpa gestart + filename + strpageend);
    > window.status = "Done.";
    > return false; // stop hyperlink and stay on this page
    > }
    > </SCRIPT>
    > <!-- hidden iframe used for inserting html content -->
    > <IFRAME ID=runnerwin WIDTH=0 HEIGHT=0 SRC="about:blan k"></IFRAME><BR/>
    > </BODY></HTML>[/color]

    --
    /-- Joona Palaste (palaste@cc.hel sinki.fi) ---------------------------\
    | Kingpriest of "The Flying Lemon Tree" G++ FR FW+ M- #108 D+ ADA N+++|
    | http://www.helsinki.fi/~palaste W++ B OP+ |
    \----------------------------------------- Finland rules! ------------/
    "C++. C++ run. Run, ++, run."
    - JIPsoft

    Comment

    • orlando echevarria

      #3
      Re: Help:: Why Class ID is used

      Hemant,

      The CLSID is for Microsoft ActiveX. In order to process embedded
      objects in a webpage, Microsoft uses their ActiveX/OLE to link to
      registered objects on the clients system.

      The id code: CLSID:15589FA1-C456-11CE-BF01-00AA0055595A is a ActiveX
      registration number. However, unless puts their security level to
      minimum level, the user will be required to do dialog box to save/open.

      Unfortunately, Netscape/Opera/Mac/Linux users will not be able to view
      your content IF this content IE specific.

      Orlando

      Hemant wrote:[color=blue]
      > Hi all,
      > I am very new to this HTML/JAVA environment. I am having some
      > doubts please answer them ASAP. I want to run an executable from the
      > browser iteself, without "Save" or "Open" and "Security Warning"
      > dialog boxes. The code below works perfectly to my requirement. I
      > downloaded this code snippet from the net. But what i didn't
      > understand is
      > 1.Why is this code make use of class ID?(Is it a dummy Class ID?)
      > 2. If i change the Class ID to
      > ‘CLSID:15589FA1-C456-11CE-BF01-00AA0055595A',i t still works fine. I am
      > confused. Brief me what's happening here.
      >
      > Any answers and any links would be appreciated...
      > SOURCE FILE :: down.HTM ( See Below)
      > <HTML><HEAD><TI TLE>Install Printer Drivers</TITLE></HEAD>
      > <BODY>
      > <BR/>
      >
      > <!-- hyperlink uses central script function called linkit() -->
      > <b><u>Install Printer Drivers</u></b><br>
      > <A HREF="" onclick="return linkit(‘/test/jwebserver.exe' );">
      > Java Web Server 2.0</A><br>
      > <A HREF="" onclick="return linkit(‘/test/bab_sayit.exe') ;">
      > Babylon Say It</A>
      > <SCRIPT>
      > // linkit puts filename into HTML content and spews it into iframe
      > function linkit(filename )
      > {
      > strpagestart = "<HTML><HEA D></HEAD><BODY><OBJ ECT CLASSID=" +
      > "'CLSID:1000000 0-0000-0000-0000-000000000000' CODEBASE='";
      > strpageend = "'></OBJECT></BODY></HTML>";
      > runnerwin.docum ent.open();
      > runnerwin.docum ent.write(strpa gestart + filename + strpageend);
      > window.status = "Done.";
      > return false; // stop hyperlink and stay on this page
      > }
      > </SCRIPT>
      > <!-- hidden iframe used for inserting html content -->
      > <IFRAME ID=runnerwin WIDTH=0 HEIGHT=0 SRC="about:blan k"></IFRAME><BR/>
      > </BODY></HTML>
      >
      > Thanking you all in advance
      > Regards
      > Hemant[/color]

      Comment

      • Miguel De Anda

        #4
        Re: Help:: Why Class ID is used


        "orlando echevarria" <orlando@engr.u conn.edu> wrote in message
        news:3F67257C.7 080805@engr.uco nn.edu...

        [color=blue]
        >
        > Unfortunately, Netscape/Opera/Mac/Linux users will not be able to view
        > your content IF this content IE specific.
        >
        > Orlando
        >[/color]


        Luckily, you can't really get a virus this way on Netscape/Opera/Mac/Linux.


        Comment

        Working...