Tuesday 15 September 2015

javascript - onClick call JSP page and render results -



javascript - onClick call JSP page and render results -

i have links on page that have onclick event. links like:

<a class='person' href='http://{urlpath}?id="+x[i].getattribute('id')+"'"+"onclick='personclick()</a>

you can see tack on user id url parameter xml returned.

because i'm using colorbox open new page when link clicked, onclick looks like:

function personclick(){ $(".person").colorbox({iframe:true, width:"80%", height:"80%"}); }

my issue this: when link clicked, need phone call jsp queries database using url parameter "id" , renders xml returned. i'm not sure how this. trying render html in same jsp database query made isn't working well. thought calling jsp queries within javascript function, using javascript dom parser parse , render data, i'm not sure how either.

i'm not sure if made problem clear or not. if not, allow me know , i'll explain further.

javascript html jsp

No comments:

Post a Comment