Hi everybody, I am Chaitanya, I got a doubt, can I use jsps and jsfs both in one single appliation, can a jsp communicate with jsf, besides I dont have any knowledge about jsf, I am just asking because I got a doubt.
JSF pages are JSPs. (unless you are talking about Facelets, but that is a different topic) They just use a set of tag libraries that are specific to JSF and it's own lifecycle. JSF pages communicate via managed beans (some form of a controller). I don't know about communication between a non-JSF JSP and a JSF page itself via the managed bean. You'll probably have better luck with this in the JSF forum, so I'll move it there.
I hate to contradict you, Gregg, but JSP JSPs are not "real" JSPs!
JSF is a Model/View/Controller system where the ".jsp" or ".xhtml" files are View prototypes.
In a normal JSP, the JSP is compiled to produce a servlet and the tags are enlisted in the execution of that servlet. Also, the URL is implicitly mapped to that servlet. In JSF, a URL mapping in web.xml routes JSF URLs to the FacesServlet. The FacesServlet is responsible for getting the View Prototype compiled into internal JSF constructs. This is one of the prime reasons that logic-oriented JSTL and scriptlets give so many problems when used in JSF View definitions.
It is perfectly legal to mix JSPs, Servlets, and even other frameworks such as Struts into a JSF application. In some cases, that's even preferable, since, for example, it's easier for a custom servlet to create a PDF than to badger the JSF framework to do so, since JSF is normally trying to render HTML, not PostScript. The difference between a JSP and a ".jsp" that's actually a JSF View prototype is strictly in whether or not the URL that makes the request matches the pattern that maps URLs to go to the FacesServlet. If it matches, it's JSF. If it doesn't, it's processed as a traditional JSP. If the JSP has JSF tags but is executed as though it were a traditional JSP, unhappiness results, as many of us have discovered to our sorrow. For one thing, the FacesContext won't have been constructed.
An IDE is no substitute for an Intelligent Developer.