Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Cloud/Virtualization forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

jQuery Ajax Calling Struts Action class

 
Joe Harry
Ranch Hand
Posts: 10088
3
Eclipse IDE Mac PPC Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Guys,

I'm trying just what this posts title says. Here is my sample:



The form in Struts notion is:



The rendered html on the browser is:



Why would alert(this.href) print undefined?
 
Joe Harry
Ranch Hand
Posts: 10088
3
Eclipse IDE Mac PPC Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Looks like there is no href attribute for a submit button. This is why I get to see undefined. Please correct me if I'm wrong.
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 64631
86
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
That's correct. Why would you think that there was? Do you not have an HTML reference handy?
 
Joe Harry
Ranch Hand
Posts: 10088
3
Eclipse IDE Mac PPC Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Actually in all these years of my programming experience, I always had little to do with HTML and Javascript stuff. But now I wanted to get hands on for a project that I'm developing during my spare time. So it is learning on the go and I find it quite interesting. I do not want to forget to mention that Javaranch is like my mentor here.
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 64631
86
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Get yourself some good references on HTML and JavaScript, else you're really flying blind.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic