Results 1 to 2 of 2
  1. #1
    moshiksa1 is offline Member
    Join Date
    Dec 2011
    Posts
    1
    Rep Power
    0

    Default how to pass a value from javascript to jsp\servlet?

    hi,

    could someone please tell how to pass the screen.width value from javascript to a jsp or servlet?

    thank you.

  2. #2
    Join Date
    Oct 2011
    Location
    Chennai, India
    Posts
    2
    Rep Power
    0

    Default Re: how to pass a value from javascript to jsp\servlet?

    One way is that you can make an ajax hit to the jsp or servlet and pass this screen.width var to it.
    In case you want to use the screen width on the same page , you can do location.href to the same page with that parameter..
    Hope it will work..
    :)

Similar Threads

  1. To pass bean property values to a javascript function and generate dojo datagrid.
    By Chinnu55 in forum JavaServer Pages (JSP) and JSTL
    Replies: 1
    Last Post: 11-13-2011, 03:06 PM
  2. Replies: 1
    Last Post: 01-02-2011, 07:23 PM
  3. How to pass a javascript function into APPLET PARAM
    By Ambergahill in forum Java Applets
    Replies: 0
    Last Post: 11-28-2010, 04:57 PM
  4. How to pass value from servlet to midlet?
    By sharmaj2me in forum CLDC and MIDP
    Replies: 1
    Last Post: 12-05-2008, 03:52 PM
  5. how to pass a List from a servlet to javascript..
    By hussainzim in forum Java Servlet
    Replies: 2
    Last Post: 09-09-2008, 12:17 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •