Replacing client side javacript

Discussion in 'Javascript' started by Prashanth, Aug 6, 2003.

  1. Prashanth

    Prashanth Guest

    Hi,

    The application we are developing will be used worldwide by various
    individuals and organizations . As part of the security restrictions ,
    some of the organization will disable client side javscript in their
    browsers. SO currently we are in the process of replacing client side
    javascript with server side javascript. There are some pages we have
    used eventtriggers like onchange,onclick, etc . When a user restricts
    scripts as part of the security restrictions , these event triggers
    are not working. So is there any way to handle these type of
    situations. Also, please let me know if anyone has a alternative
    solution to replace client side javascript.

    thanks in advance,
    Prashanth C N
     
    Prashanth, Aug 6, 2003
    #1
    1. Advertising

  2. Prashanth

    Evertjan. Guest

    Prashanth wrote on 06 aug 2003 in comp.lang.javascript:
    > The application we are developing will be used worldwide by various
    > individuals and organizations . As part of the security restrictions ,
    > some of the organization will disable client side javscript in their
    > browsers. SO currently we are in the process of replacing client side
    > javascript with server side javascript.


    1
    <script>location.href="js-index.html"</script>
    <noscript>
    You seem to have disabled your browser's javascript,<br>
    so you cannot use this site.<br>
    Bye.
    </noscript>

    or:

    2
    Use serverside scripting exclusively, without clientside event trapping
    like onclick. All click-events must be <a href=""> and all
    mousover/mousout replaced by css-styles a:hover

    =============

    I prefer solution 1, because you should expect some involvement from your
    audience. Tell them that the only safe internet connection is no
    connection at all, only leased line intranet.

    That is not to say that I prefer to use serverside scripting as much as
    possible, because you can depend more on your debugging than with all the
    browsers and browserversions available.

    --
    Evertjan.
    The Netherlands.
    (Please change the x'es to dots in my emailaddress)
     
    Evertjan., Aug 6, 2003
    #2
    1. Advertising

  3. (Prashanth) writes:

    > The application we are developing will be used worldwide by various
    > individuals and organizations . As part of the security restrictions ,
    > some of the organization will disable client side javscript in their
    > browsers.


    Predictable.

    > SO currently we are in the process of replacing client side
    > javascript with server side javascript.


    I assume you are using ASP w/ JScript on the server then. That
    is the only kind of server-side Javascript I know of.

    > There are some pages we have used eventtriggers like
    > onchange,onclick, etc . When a user restricts scripts as part of the
    > security restrictions , these event triggers are not working. So is
    > there any way to handle these type of situations.


    Nothing except the principles that you should always follow on
    professional pages: If Javascript is not *essential* to your page
    (i.e., it cannot ever work without it and the computation cannot be
    performed server-side), then make sure it works without Javascript. If
    Javascript is essential, say so to people without it.

    > Also, please let me know if anyone has a alternative solution to
    > replace client side javascript.


    For simple things like mouseovers, you can use CSS. Sadly, IE's CSS
    is not very advanced, so you probably cannot do your menues entirely
    in CSS.

    For things like form validation, it should be performed serverside
    already (never trust the client!)

    For actual computations (e.g., adding numbers), there is no
    alternative to doing it on the server. There is only the client and
    the server involved, and the client won't do it.

    /L
    --
    Lasse Reichstein Nielsen -
    Art D'HTML: <URL:http://www.infimum.dk/HTML/randomArtSplit.html>
    'Faith without judgement merely degrades the spirit divine.'
     
    Lasse Reichstein Nielsen, Aug 6, 2003
    #3
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. darrel
    Replies:
    2
    Views:
    2,264
    Alphonse Giambrone
    Mar 25, 2005
  2. Jason Chan
    Replies:
    1
    Views:
    601
    cbDevelopment
    Dec 3, 2005
  3. Boss302
    Replies:
    0
    Views:
    1,086
    Boss302
    Nov 21, 2006
  4. Bogdan
    Replies:
    2
    Views:
    678
    Bogdan
    Jun 9, 2008
  5. Zoe Hart
    Replies:
    1
    Views:
    389
    Scott Wisniewski
    Jan 8, 2004
Loading...

Share This Page