| Author |
HFSJ Chapter 7 Page 341
|
Suhas Wadadekar
Ranch Hand
Joined: May 16, 2006
Posts: 95
|
|
The explanation to Question 15 says,
"Options A and D are invalid because only Java statements may be included within <% .... %> tags"
Option D <% import java.util.Date; %> looks pretty much correct Java syntax to me. I must agree I was confused by this answer choice and even confused by the answer/explanation.
Thanks,
Suhas
|
 |
Ankit Garg
Saloon Keeper
Joined: Aug 03, 2008
Posts: 9189
|
|
Everything between the <% and %> goes inside the service method of the converted servlet of the JSP. So if you write <% import java.util.Date; %>, it will look like
|
SCJP 6 | SCWCD 5 | Javaranch SCJP FAQ | SCWCD Links
|
 |
Suhas Wadadekar
Ranch Hand
Joined: May 16, 2006
Posts: 95
|
|
|
Makes sense Ankit. Thanks for pointing that out. I was definitely not paying attention to what I was reading.
|
 |
 |
|
|
subject: HFSJ Chapter 7 Page 341
|
|
|