• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

JSP and AJAX problem

 
Supratim Das
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I wrote this code in jsp where in have sent the request from ajax......



in the AJAX file, I have written this to print it.......



the data is dynamically loaded perfectly into the page....but the submit buttons do not work..........when I right clicked on the browser page and clicked on "view source"......it does not show the html code of the dynamically loaded portion of the page.......

How Can I resolve this problem........?? PLEASE HELP........
 
Ulf Dittmer
Rancher
Pie
Posts: 42967
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
but the submit buttons do not work

Are there any error messages in the JavaScript Console?

when I right clicked on the browser page and clicked on "view source"......it does not show the html code of the dynamically loaded portion of the page

That's to be expected if you add HTML dynamically.

Post the HTML that does get created.

Also, you shouldn't have several HTML form elements with the same name.
 
Supratim Das
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
there is no error msg in the javascript console.......


and there is no change in the html code before and after the dynamic load.....when I see it from the "view source" option....... the dynamically loaded table is shown in the browser......but it is not reflected to the code when i see from the "view source" option....



the code stays like this even after the loading of dynamic table....
 
Ulf Dittmer
Rancher
Pie
Posts: 42967
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
As I said, that is to be expected.
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 64618
86
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Ulf Dittmer wrote:
Also, you shouldn't have several HTML form elements with the same name.

It is actually perfectly ok to have multiple form element with the same name. It's the id values that need to be unique.

 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 64618
86
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If you want to see the dynamically created DOM, you'll need to use the browser's JavaScript debugger. View Source will always show you the source.

P.S. Java scriptlets in JSPs? In 2012? :shock:
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic