0

I was wondering if in Spring MVC I can add server controls in my jsp pages, like I do in ASP.Net with <asp:textbox> for example.

All the examples I see on the Internet use javascript controls...

Pacane
  • 20,273
  • 18
  • 60
  • 97
  • Or HTML controls I should say... – Pacane Sep 26 '12 at 05:53
  • Again, "HTML controls"? The word "control" is not used in the context of HTML except to describe the `` elements, and it isn't used at all in the context of Javascript or Java (where they're refered to as widgets or components). – Dai Sep 26 '12 at 05:54
  • Well, I was referring to tags I guess. I was wondering if I could use some user controls, like specially formatted textboxes for example. – Pacane Sep 26 '12 at 05:57
  • 1
    @Dai - I think there's enough context to understand what the OP means. – Jared Farrish Sep 26 '12 at 05:58
  • Isn't [JSF supposed to be replacing JSP](http://myfaces.apache.org/jsfintro.html)? The [Spring MVC Showcase](https://github.com/SpringSource/spring-mvc-showcase/blob/master/src/main/webapp/WEB-INF/views/fileupload.jsp) uses [JSTL](http://stackoverflow.com/questions/3715484/what-is-jstl-and-the-different-between-the-jsp), which according to the Oracle "doc" page, is fully compatible with JSF (or the other way around). – Jared Farrish Sep 26 '12 at 06:07

2 Answers2

0

JSP has the concept of "JSP Tags" which are similar in functionality to ASP.NET WebForms Controls, but they have their differences.

I'm not familiar enough with JSP or Spring to enumerate the differences or similarities, but I can only suggest you give this page a read: http://www.tutorialspoint.com/jsp/jsp_standard_tag_library.htm

Dai
  • 141,631
  • 28
  • 261
  • 374
0

Well, there are a lot of JSP tags to render HTML controls, usually they are bundled with web framework like struts / spring mvc. There is also JSF technology which provides component model to render HTML pages and interact with server side model.

However, main purpose of spring is to provide DI container for easier development and component management, but there is also integrated web framework ( though my personal choice would be struts with nanocontainer)

Konstantin Pribluda
  • 12,329
  • 1
  • 30
  • 35