Computing.Net > Forums > Web Development > calling .jsp script

Computer Problems? Computing.Net has over 1,000,000 posts about all things technology related! Over 90% answered within 24 hours! Click here to start participating now! Also, be sure to check out the New User Guide.

calling .jsp script

Reply to Message Icon

Name: liliyaw
Date: June 29, 2006 at 14:57:20 Pacific
OS: linux
CPU/Ram: 524
Product: don't know
Comment:

Hi everyone,
Does anybody know how to call a jsp script with a value in javascript?
I know there is a way to go to a different page, the syntax is
window.location.replace('jobedit.jsp?id="+intItemID+"&cmd=upfb');
but I need to stay in the same window and execute the script



Sponsored Link
Ads by Google

Response Number 1
Name: Michael J (by mjdamato)
Date: June 29, 2006 at 15:27:42 Pacific
Reply:

This article may help. It is about calling a PHP script from JavaScript without actually loading a page. Don't see why it wouldn't work for JSP as well:

http://www.phpit.net/article/php-on-the-fly/

Michael J


0

Response Number 2
Name: Laler
Date: June 29, 2006 at 17:13:16 Pacific
Reply:

ajax? I'm currently building one with it. It's so hard to make it work on IE, firefox & opera without understanding javascript's DOM (which I don't).

This is the tutorial I'm trying to implement, their example work on that 3 browsers: http://www.yourhtmlsource.com/javascript/ajax.html

The example page: http://www.yourhtmlsource.com/examples/ajaxformsubmission.html

---


0

Response Number 3
Name: Laler
Date: June 29, 2006 at 17:22:33 Pacific
Reply:

Rasmus' 30 second AJAX Tutorial was my first tutorial :D A quick read if you just want to understand the conecpt, but it breaks my layout in opera.

---


0

Response Number 4
Name: Laler
Date: June 29, 2006 at 17:33:37 Pacific
Reply:

and this is nice too :-D

http://mentalized.net/activity-indicators/

as most people will think there's something wrong when nothing happens when they click.

---


0

Response Number 5
Name: liliyaw
Date: June 30, 2006 at 10:10:42 Pacific
Reply:

Well, at this point, I'm using javascript to do POST to my request processing jsp page. The issue now - I'm ready to send back data from that jsp page into the client view page and I'm not sure what has to happen on the client side to show the data.


0

Related Posts

See More



Response Number 6
Name: Laler
Date: June 30, 2006 at 12:46:34 Pacific
Reply:

You want to do it asynchronously right? Only some of the content changed, not the whole page? Take a look at the 30 second tutorial written by Rasmus above, you'll get a good grasp on what should be done.

I'm not sure what has to happen on the client side to show the data

In short, the page change its content by using javascript (which is what it can do best, change things on the client side), but the content is taken from another file, as a result of a request to that file (.php file or any).

In the example page in response #2, the 'processor' outputs data in XML format, while in Rasmus' tutorial it outputs plain text with | as delimiter. string before the | is used as a marker for what div (or any) ID should change its content.

---
Site of the Day


0

Sponsored Link
Ads by Google
Reply to Message Icon






Post Locked

This post is quite old and has been locked from receiving new replies. Please create a new posting instead.


Go to Web Development Forum Home


Sponsored links

Ads by Google


Results for: calling .jsp script

Calling java script functions www.computing.net/answers/webdevel/calling-java-script-functions/1166.html

making javascript libs? www.computing.net/answers/webdevel/making-javascript-libs/2403.html

PHP and how to call it? www.computing.net/answers/webdevel/php-and-how-to-call-it/3627.html