• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

web pages: which technology

 
Ranch Hand
Posts: 516
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Ranchers!

I need your input once more!

before I ask my question, I just want to say that I don't know much about web pages programming...

I want to do a dynamic web page, in Java related technologies.

As far as I know, I could do that in several ways :
- servlet
- JSP
- JSF
- Struts

I know JSF is just some extra tags to use in JSP. And, correct me if I'm wrong, JSP is compiled as servlet?

Among these technologies, If I were to learn one (for the future), which one would be a good bet?

I'm tempt to do a servlet because I know SWING very well... and it would be quite easy (for me) I believe.

JSP looks like a hard road to me.. and a jump in the past.

I did some JSF, I believe this could be good one day.. but they're no free web hosting for it as far as I know.

And struts.. well..don't know about it.

First of all.. is servlet a good way to do web pages? It sounds so easy, that I wonder why they are other ways of doing web pages...
Whays the downside of servlets?

Any comments will be appreciated.

Best Regards,
Alex
[ January 31, 2006: Message edited by: Alex Turcot ]
 
Sheriff
Posts: 14691
16
Eclipse IDE VI Editor Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

And, correct me if I'm wrong, JSP is compiled as servlet?


True.

which one would be a good bet?


Servlet + JSP. You could study to pass SCWCD.

I'm tempt to do a servlet because I know SWING very well... and it would be quite easy (for me) I believe.


Servlet and Swing have nothing in common. Swing is as you know some interface stuff. Servlet is not used for presentation, nor gui.

JSP looks like a hard road to me.. and a jump in the past.


Actually, it's not very hard once you know the basics.
But for putting this into practice, you'll probably want to learn more about EL and JSTL as well (which are also part of SCWCD)

Grab a book like Head First Servlet and JSP and you'll understand all the basics.

Have fun.
 
Alex Belisle Turcot
Ranch Hand
Posts: 516
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks for your response...

I made a mistake in my post however...
I forgot about applet, and I meant "applet" when comparing with SWING.

"I'm tempt to do an applet because I know SWING very well... and it would be quite easy (for me) I believe."

Is applet a good choice?

Regards,
Alex
[ January 31, 2006: Message edited by: Alex Turcot ]
 
Ranch Hand
Posts: 63
Oracle Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Alex
You are right.JSP is a compiled into a servlet.
Regarding technologies,the downside of using servlets is there will be too many out.print statements in ur java code. besides your html code will be interspersed with the java code.

using servlet-jsp combination would be a good approach.
servlet for the navigation part and jsp for the view part.

U could start reading about struts,which is a framework rather than a technology.The ranch site for struts is a good place to start off with.i am not very familiar with Java Swings,i belive is also more or less based on MVC architecture.

hth
thanks
cheers
vinnym
 
Sheriff
Posts: 67746
173
Mac Mac OS X IntelliJ IDE jQuery TypeScript Java iOS
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

JSP looks like a hard road to me.. and a jump in the past.



Huh? "a jump in the past"?

Applets, however, are considered passe by many.

In any case, I would avoid frameworks like JSF and Struts until you have a good handle on how Servlets and JSP work.
 
Alex Belisle Turcot
Ranch Hand
Posts: 516
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thats really why I ask...

I would be tempt to do applets... but I know some people consider it to be history..

I did JSF for a while, even tho im not an expert at all.. I do understand how stuff works a little bit (simply made a mistake in my first post using "servlet" when really I meant "applet").

About JSP being a jump in the past, let me explain myself. It's just my personal opinion: pure JSP (meaning not with jsf for instance) is simply scripting and is quite far from OO programming. However I never did pure JSP and thats why I'm asking your opinions, because I don't know enough on the subject.

I'm looking for the best choice of technology to spend some time on..

Applet looked like the easy path, but again I read was outdated..

Thanks,
Alex
 
Bear Bibeault
Sheriff
Posts: 67746
173
Mac Mac OS X IntelliJ IDE jQuery TypeScript Java iOS
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

pure JSP (meaning not with jsf for instance) is simply scripting



You've been out of the loop for a while, haven't you?

With JSP 2.0 the move is strongly away from any scripting on the pages, and towards completely scriptless pages using technologies like the JSTL (JSP Standard Tag Library) and EL (Expression Language), and making use of custom actions developed using the new and simpler tag handling mechanisms.

Usually a servlet is used as a front controller to perform any processing, and then forwarding to a JSP page to render the view.
[ January 31, 2006: Message edited by: Bear Bibeault ]
 
Christophe Verré
Sheriff
Posts: 14691
16
Eclipse IDE VI Editor Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

is simply scripting and is quite far from OO programming.


You'll do all the OO programming in Java.
JSP is used for presentation and has all the necessary stuff.

You need to read something about JSP2.0.
There is a good start :
http://www.onjava.com/pub/a/onjava/2003/11/05/jsp.html
(but you'll need to know JSP basics first)
 
Alex Belisle Turcot
Ranch Hand
Posts: 516
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
yea you could say that.. that I was out of the loop..

Thanks for the tips on jsp2.0.. I'll read more on the subject.

And I guess jsp2.0 is prefered to applets?
 
Christophe Verré
Sheriff
Posts: 14691
16
Eclipse IDE VI Editor Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
It seems that you have a wrong conception of what JSP is.
The OO programming is done in Java behind.
JSP should be only used for presentation.

You should read something about JSP2.0 first.
http://www.onjava.com/pub/a/onjava/2003/11/05/jsp.html
(JSP basics needed)
 
Bear Bibeault
Sheriff
Posts: 67746
173
Mac Mac OS X IntelliJ IDE jQuery TypeScript Java iOS
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Well, they're very different technologies.

Do you want to deliver an applet to the browser, or do you want to create a web application?
 
Alex Belisle Turcot
Ranch Hand
Posts: 516
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I see I lack so much of skills on the subject, Im having trouble just to fomulate my questions..


The only front end (web page) I did was with JSF. I had to use my JSF tags from a JSP.

So beside using JSP for JSF, to me, JSP was some scripting... I understand now that JSP 2.0 uses the JSTL... (I guess JSF is just some Extra tags..).

So they're some tags I can use in JSP to do my presentation.

Would it be true to say that JSF is actually JSP with extra tags on top of the Standards ones?

Big thanks to everyone for your help.
I was far far away..

Regards,
Alex
 
Christophe Verré
Sheriff
Posts: 14691
16
Eclipse IDE VI Editor Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
JSF is more than a simple collection tags.
From the J2EE Tutorial:

The main components of JavaServer Faces technology are as follows:
# An API for representing UI components and managing their state; handling events, server-side validation, and data conversion; defining page navigation; supporting internationalization and accessibility; and providing extensibility for all these features
# Two JavaServer Pages (JSP) custom tag libraries for expressing UI components within a JSP page and for wiring components to server-side objects
 
Ranch Hand
Posts: 2874
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Alex Turcot:
Would it be true to say that JSF is actually JSP with extra tags on top of the Standards ones?



JSF is just a web framework like Struts and Tapestry are. Do not confuse JSF with JSP/JSTL.

JSP is a server-side J2EE web-tier technology used for presentation.

JSTL is a tag library to use with JSP. Its main purpose is to replace scriplets and make the JSP page clean and clear.
 
Adeel Ansari
Ranch Hand
Posts: 2874
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
After going through the whole discussion. I would like to suggest you to learn servlet technology first after that you will get the idea.
 
Christophe Verré
Sheriff
Posts: 14691
16
Eclipse IDE VI Editor Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

JSF is just a web framework like Struts and Tapestry are. Do not confuse JSF with JSP/JSTL.



I wouldn't call JSF a framework (and would not assimilate it to Struts either), but a technology used to simplify making user interfaces.
 
Adeel Ansari
Ranch Hand
Posts: 2874
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Satou kurinosuke:
I wouldn't call JSF a framework (and would not assimilate it to Struts either), but a technology used to simplify making user interfaces.



Sorry if my statement confused you. I meant that JSF is a web framework as popular Struts is a web framework. It doesn't mean that JSF is like Struts or does like Struts. Not at all.
Thanks.
 
Alex Belisle Turcot
Ranch Hand
Posts: 516
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thank you all.. I'll start from here.

Even tho I still got everything to learn on this topic, I do have a better overview now.

Thanks again,
Alex
 
Greenhorn
Posts: 22
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I know JSF is just some extra tags to use in JSP. And, correct me if I'm wrong, JSP is compiled as servlet?


Yes internaly jsp will compailed as a servlet.

JSP looks like a hard road to me.. and a jump in the past.

JSP is not hard,when you know the key part of JSP it is very easy,
For better you gothrough headfirst Servlets and JSP.
 
Ranch Hand
Posts: 294
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
The is a new technology some may name as Ajax. However it's something different. So imagine that you can no M no V no C. Of course you have no servlets, JSP, JSF, taglibs, applets, and many frameworks around them. So what you have? SOA. It means that you have set of service provider objects capable to serve SOAP requests(some name them webservices though). Now you load a static page with JavaScript engine on it. This engine reads UI definition from service providers and render UI, interact with users, validate data and send updates to service providers. So, this technology completely eliminate most of old servelt based technologies. UI coming is very sleek and appealing. So, if you are just starting, then you have a chance to leverage technologies on XXI century.
 
Get meta with me! What pursues us is our own obsessions! But not this tiny ad:
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic