Cry or laugh?
There's another Java related website at roseindia.net which hosts lot of basic Java EE tutorials along a huge mass of advertisements. There are also some JSF tutorials over there. Since I saw that site for the first time, about 1.5 years ago, I quickly realized that almost every article and code sample at that site must be taken with a huge bag of salt. But OK, I thought, that kind of websites unfortunately exist, nothing to do against, so I ignored it for the rest of the time.
And today, while surfing over the net I accidently came across http://www.roseindia.net/jsf/actionListener.shtml (screenshot). Now I don't know whether I have to cry or laugh about it. Initially I laughed hard, very hard. Running a Swing JOptionPane component from inside a server side Java class with the intention to display a message at the client side!! And showing that off as a tutorial?!? But then I realized that there might be many new-to-JSF developers who came across the roseindia.net site and took the gross of the articles for serious and implemented it for production. Ouch, that hurts! Also see the comments at the bottom of that article.
Update: here and here are another examples of a horror story related to roseindia.net. A poor programmer decided to implement the JSP file upload example as described at http://www.roseindia.net/jsp/file_upload/Sinle_upload.xhtml.shtml (ouch, note the typo and double extensions in the roseindia.net URL, how professional). The code example is bad in almost every way. The HTML code contains nasty uppercases (the author is apparently hanging in the '90s HTML style). The HTML code contains the
Update 2: another horror story can be found here. One decided to download and install JSTL using the procedure as described at http://www.roseindia.net/jstl/downloading-jstl.shtml. Did you read it? It suggests to extract the complete JAR file, duplicate all of its TLD files in the WEB-INF and duplicate all of the TLD declarations in the web.xml of every webapplication which is going to use JSTL. Terrible. Just placing the JAR files in the classpath was been enough. The myth of extracting the JAR file is only applicable if you have downloaded the wrong JSTL version for your webapp which causes that EL (those ${}
things) in JSTL tags may possibly fail. For more detail of the proper approach, read JSTL wiki page on stackoverflow.com.
Lesson learned: if you are new to Java EE, do not use roseindia.net! It might contain some good articles -which are generally copypasted/rephrased/changed from actually good sources (I've seen exact copypastes of parts of official TLD and API documentations, e.g. Tomahawk TLD and Java Servlet API, how lame..), or are in very rare cases just by coincidence good-, but for the rest it only introduces bad practices and/or contains stupid examples. That site almost seems to be maintained by amateurs with zero professional experience and targeted on the advertisement incomes only. If you are new, you never knows which is good and which is bad. So, just ignore that site. Forever.
Good JSF sites
At least here is a list of trusted and good JSF 1.2 related sites:
- JSF 1.2 specification document (pick the 1st download link) explains why JSF is there, how it works and what it all provides.
- JSF 1.2 API documentation contains detailed javadocs of the JSF API classes, it explains where the classes are for, how to use them and what all fields/methods do.
- JSF 1.2 tag library documentation shows which JSF tags are all available, what they all do and which attributes they supports.
- Sun Java EE 5 tutorial part II chapter 10 and on contains Sun's own JSF 1.2 tutorial.
- Coreservlets.com JSF 1.2 tutorial another good and serious JSF tutorials with downloadable ready-to-use code samples.
- JSFTutorials.net a link collection of a lot (mini) JSF tutorials spreading over the net.
- If you want to get a book, I highly recommend the JSF: The Complete Reference, one of its authors, Ed Burns, is the lead of the JSF specification.
Update: we're now already at JSF 2.0/2.1, here's a list of trusted and good JSF 2.0/2.1 related sites:
- JSF 2.0 specification document (pick the 1st download link) explains why JSF is there, how it works and what it all provides.
- JSF 2.1 API documentation contains detailed javadocs of the JSF API classes, it explains where the classes are for, how to use them and what all fields/methods do.
- JSF 2.1 tag library documentation shows which JSF tags are all available, what they all do and which attributes they supports.
- Oracle Java EE 6 tutorial part II chapter 4 and on contains Oracles's own JSF 2.0 tutorial.
- Coreservlets.com JSF 2.0 tutorial another good and serious JSF tutorials with downloadable ready-to-use code samples.
- JSFTutorials.net a link collection of a lot (mini) JSF tutorials spreading over the net.
- If you want to get a book, I highly recommend the JSF 2.0: The Complete Reference, one of its authors, Ed Burns, is the lead of the JSF specification.
And, of course, the JSF related articles at this blog. Check them out at the 'Tags' or 'Articles' section in the right column. The JSF wiki page at stackoverflow.com is also a nice starting point. Further I've collected all top Stack Overflow answers at JSF.ZEEf.com.
Source:http://balusc.blogspot.com/2008/06/what-is-it-with-roseindia.html
Tidak ada komentar:
Posting Komentar