First of all, which App server are you using? What is the error message you're getting?
The
JSP 1.2 spec doesn't come out and say this is legal or not, the only relative line I could find was this:
JSP7.5 Validation
There are a number of reasons why the structure of a JSP page should conform to some validation rules:
* Request-time semantics: eg. a subelement may require the information from some enclosing element at request-time
So... according to that, it seems as though its possible... but of course it also seems up to the interpretation of the Application Server Developer.