Imagine this simple form for uploading a file:
<form action="upload" enctype="multipart/form-data">
<input type="text" name="name"/>
<input type="file" name="file"/>
<input type="submit"/>
</form>
If there is some error ... |
I have a RESTEasy service that returns a HTTP 500 when a server side error occurs. I manage to attach a body to the HTTP response in order to give more ... |
I'm noob to Spring. I'm using :
- Apache Tomcat 6.0.20
- Spring 3.x
I want to create simple "Hello World !!!" on my index page. Unfortunately i got the following error:
org.springframework.web.util.NestedServletException: Handler processing failed; ...
|
I'm mapping my request's JSON POST data into an object using Spring's @RequestBody annotation and MappingJacksonHttpMessageConverter. However after that I'd like to read the data in String form to do some ... |
I'm trying to add an image upload in my freemarker page(ftl file) using spring and hibernate technology -
this is the error I had every time I run the application :
... |
currently my solution is
For AJAX:
@RequestMapping(value = "/verify", method = {RequestMethod.GET},
headers = "x-requested-with=XMLHttpRequest")
public
@ResponseBody userTO
void ...
|
Please take a look at codes below. Four text boxes are displayed.
If I input "1" and "2" to former text-boxes, these are binded as comma-separated "1,2" as I expected.
However, if I ... |
|
I am using the Spring annotation @ResponseStatus in my Exception like
@ResponseStatus(value=HttpStatus.UNAUTHORIZED)
public class UnauthorizedException extends Exception{
}
Problem is I want to throw the same error for a number of values like HttpStatus.SC_SERVICE_UNAVAILABLE, etc..
Is ... |
I found that, by default when I using Spring MVC, "2010/01/02" binds correctly, but "2010-01-02" does not.
I know Spring has some useful binding mechanisms like initBinder. However, in this question I ... |
I have a Spring-MVC webapp (3.0.5-RELEASE) which needs to access JSON webservices from another webapp on a different sub-domain (from the client/browser via AJAX).
I've solved this in the past by ... |
I have this code (like in Spring's reference):
<bean id="multipartResolver"
class="org.springframework.web.multipart.commons.CommonsMultipartResolver">
<!-- one of the properties available; the maximum file size ...
|
This sounds like a trivial question but somehow I can't seem to figure it out.
I have a Spring MVC application. I don't support any http methods except GET and POST. I ... |
While using @RequestBody StreamSource found out, that if xml in request body in not valid StreamSource throws an Exception(resulting in 400 Bad Request) and i'm not able to handle it(tell client ... |
I have a SpringMVC web service for uploading files which looks like this:
@RequestMapping(value="/upload.json", method = RequestMethod.POST)
public @ResponseBody Map<String, Object> upload(MultipartHttpServletRequest request) {
// upload the file
}
and everything is ... |
|
I have a simple Spring 3.0 controller with a PUT request mapping
@Controller
public class FooController {
@RequestMapping(value = "/foo/{id}", method = RequestMethod.PUT)
public @ResponseBody FooView put(@PathVariable ...
|
Sorry to be so unspecific with title and tags. I have a problem with URL requests to Tomcat in a simple failover scenario with multiple applications being involved. A strange error ... |
This has been bugging me for days and I'm turning to the community for help. I've been trying to access the request body and headers using the HttpEntity as suggested by ... |
Configuration problem: Unable to locate Spring NamespaceHandler for XML schema namespace [http://www.springframework.org/schema/mvc].
can anyone tell why this error is happening?
this is my configuration.
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:mvc="http://www.springframework.org/schema/mvc"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:context="http://www.springframework.org/schema/context"
xsi:schemaLocation="http://www.springframework.org/schema/beans
...
|
By having the following code:
@RequestMapping(value = "/system/login", method = RequestMethod.GET)
public void login(@RequestBody Login login) {
if(login.username == "test" && login.password == "test") {
...
|
This seems like a pretty basic question but I unfortunately don't know the answer and can't seem to find it.
I'm trying to understand the lifecycle of an initial POST/GET to a ... |
I have some trouble with Spring HTTP message conversion. In my app I have the login form.
When registered user try to login he get the login error ( redirect to /login?login_error=1)
The ... |
I'm working on a proxy servlet that maps all requests.
I specified web.xml in the following way:
<servlet>
<servlet-name>appServlet</servlet-name>
<servlet-class>org.springframework.web.servlet.DispatcherServlet</servlet-class>
<init-param>
...
|
I am following a tutorial, and i got the following HTTP Error 500. I am unable to solve this even after googling it since yesterday. Can someone help me ... |
Hi, as far as I could see, HTTP byte-range requests aren't supported by the ResourceHttpRequestHandler (as configured with ). Is there any other way to make this work? I'd like to ... |
HTTP to HTTPS in spring MVC I've googled around without much luck. For example I have a SimpleFormController and I want to redirect the client to a secure HTTPS page "new_view.htm" ... |
Question: How to setup http sesson management in MVC Spring Hi, I am new to spring and i not a smart guy... can anybody here teach me how to set the ... |
No mapping found for HTTP request with MVC requests I am receiving the following error: WARN org.springframework.web.servlet.PageNotFound 2008-06-17 13:37:30,140 - No mapping found for HTTP request with URI [/spring-security/WEB-INF/views/help.jsp] in DispatcherServlet ... |
Binding HTTP form fields onto model of type Map Hi, We use Spring 2.5.5 and WebFlow 2.0 for our web application. When mapping http form field values onto the underlying model ... |
Hi, Please kindly help with your expertise. Web Server got an HTTP POST and tries to do 2 things: 1. Send HTTP Response to HTTP Requester (via URL?) 2. Return Model/View ... |
Hi, Please kindly help with your expertise. Web Server got an HTTP POST and tries to do 2 things: 1. Send HTTP Response to HTTP Requester (via URL?) 2. Return Model/View ... |
Hi I have an application built with Spring ROO and I'm not sure of the best way to configure an http inbound channel adapter that will work alongside Spring MVC. In ... |
What's is the best way to handle http errors (404, 500 ect) in a way that when the error happens the controller reacts and forwards it to a page rather than ... |