Dear All,
This website has taught me lot of things since i was an engineering student. Now again i am back with a new question......
I need to read the contents of the jsp page that is using JSF framework through the Javascript.
Any help for starting the thing will be of great help.
Thanks and regards,
Himadri Sikhar Khargharia
or mdew_47
1 Replies - 397 Views - Last Post: 26 November 2010 - 03:32 AM
#1
I need to read the contents of the jsp page that is using JSF framewor
Posted 25 November 2010 - 11:27 AM
Replies To: I need to read the contents of the jsp page that is using JSF framewor
#2
Re: I need to read the contents of the jsp page that is using JSF framewor
Posted 26 November 2010 - 03:32 AM
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>JSP Page</title>
</head>
<body id="himadri">
<h1>Hello World!</h1>
<form id="help" name="help" method="post" action="/Himadri-war/faces/WEB-INF/See.jsp" enctype="application/x-www-form-urlencoded">
<input type="hidden" name="help" value="help" />
<table>
<tbody>
<tr>
<td class="rightalign"><label>
Userid: </label></td>
<td class="leftalign"><span id="help:userid">88</span></td>
</tr>
<tr>
<td class="rightalign"><label>
FirstName: </label></td>
<td class="leftalign"><span id="help:firstname">tght</span></td>
</tr>
<tr>
<td class="rightalign"><label>
Lastname: </label></td>
<td class="leftalign">ghg</td>
</tr>
<tr>
<td class="rightalign"><label>
Gender: </label></td>
<td class="leftalign">gr</td>
</tr>
<tr>
<td class="rightalign"><label>
Age: </label></td>
<td class="leftalign">43</td>
</tr>
<tr>
<td class="rightalign"><label>
Details: </label></td>
<td class="leftalign"><span id="help:Details"></span></td>
</tr>
</tbody>
</table>
<input type="hidden" name="javax.faces.ViewState" id="javax.faces.ViewState" value="2606324558782240815:-4303962549239945749" autocomplete="off" />
</form>
</body>
</html>
I need to read a page like this... I am using:
function Apply(){
alert('hello first1');
var frm = document.getElementById("help:firstname");
alert(frm);
alert('hello second2');
}
But in this case alert(frm) is showing null.... Please help me to find out the proble, by using innerHTML...even the third alert statement is not executed.... I need to get the value of the element by Id "help:firstname"...
Please help..thanks and regards
himadri
Page 1 of 1
|
|

New Topic/Question
Reply



MultiQuote



|