| Author |
HFSJ Mock Exam Question
|
Anand Labhishetty
Greenhorn
Joined: Jul 20, 2006
Posts: 3
|
|
Hi All, I am trying out the Q:63 from Mock exam. I am typing in part of the question that i have doubt - -------------------------------------------- <jsp:setProperty name="x" property="a" value="something"/> <c ut value="hello"/> -------------------------------------------- The Explanation says that we won't get any error if we use the jsp standard action. But can we use the <jsp:setProperty> without <jsp:useBean> or anything that introduces the variable "x" ? I am getting error when i tried to execute the single line of code in a JSP. Can you please explain? Also, the <c ut> is not generating any error nor even any output. The explanation says that it should generate a error.But I am not getting any. What does the spec say about it? I am using Tomcat 5.0.28. Cheers Anand
|
 |
Marc Peabody
pie sneak
Sheriff
Joined: Feb 05, 2003
Posts: 4725
|
|
|
I can guarantee that you are getting output. View the page source from your browser.
|
A good workman is known by his tools.
|
 |
Anand Labhishetty
Greenhorn
Joined: Jul 20, 2006
Posts: 3
|
|
Hi Marc, When i see the view source i can see <c ut value="hello"/> i.e., the code i have typed in. The explanation in the book says that if we use the tag without declaring the prefix, it should generate a error. Is that correct? Also, could you please explain the issue i have posted for <jsp:setProperty> ? As mentioned, I am getting an error if i include only <jsp:setProperty> tag in the JSP but the book says that it should be ok. Cheers Anand
|
 |
cheenu Dev
Ranch Hand
Joined: Nov 13, 2005
Posts: 276
|
|
there are two posts regarding this topic. refer here and here better search before you post.
|
cheenujunk@gmail.com
|
 |
Anand Labhishetty
Greenhorn
Joined: Jul 20, 2006
Posts: 3
|
|
Thanks for the providing the links cheenu. I looked for the errata of HFSJ on the net and didn't find what I was looking for, So i thought i would post it(as i was in a bit of hurry). Keeping that aside, I have finished my exam today with 92%. Would like to Thank all you guys for providing all the required info. Cheers Anand.
|
 |
Marc Peabody
pie sneak
Sheriff
Joined: Feb 05, 2003
Posts: 4725
|
|
Originally posted by Anand Labhishetty: Keeping that aside, I have finished my exam today with 92%.
Huzzah!
|
 |
 |
|
|
subject: HFSJ Mock Exam Question
|
|
|