[Users | Trunk]: Add filter for utf-8
This commit is contained in:
parent
6284ef2d2e
commit
a143109714
|
@ -0,0 +1,27 @@
|
|||
package eu.dnetlib.openaire.usermanagement.utils;
|
||||
|
||||
import javax.servlet.*;
|
||||
import java.io.IOException;
|
||||
|
||||
public class CharacterSetFilter implements Filter {
|
||||
|
||||
@Override
|
||||
public void init(FilterConfig filterConfig) throws ServletException {
|
||||
|
||||
}
|
||||
|
||||
public void doFilter(
|
||||
ServletRequest request,
|
||||
ServletResponse response,
|
||||
FilterChain next) throws IOException, ServletException {
|
||||
request.setCharacterEncoding("UTF-8");
|
||||
response.setContentType("text/html; charset=UTF-8");
|
||||
response.setCharacterEncoding("UTF-8");
|
||||
next.doFilter(request, response);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void destroy() {
|
||||
|
||||
}
|
||||
}
|
|
@ -1,8 +1,2 @@
|
|||
google.recaptcha.secret = 6LfYrU8UAAAAADwrbImPvDo_XcxEZvrkkgMy9yU0
|
||||
google.recaptcha.key = 6LfYrU8UAAAAAFsl3m2YhP1uavdmAdFEXBkoY_vd
|
||||
|
||||
registry.issuer = https://openaire-dev.aai-dev.grnet.gr/registry
|
||||
registry.user = user
|
||||
registry.password = pass
|
||||
registry.version = 1.0
|
||||
registry.coid = 2
|
||||
google.recaptcha.key = 6LfYrU8UAAAAAFsl3m2YhP1uavdmAdFEXBkoY_vd
|
|
@ -19,7 +19,15 @@
|
|||
<listener-class>org.springframework.web.context.ContextLoaderListener</listener-class>
|
||||
</listener>
|
||||
|
||||
<filter>
|
||||
<filter-name>CharacterSetFilter</filter-name>
|
||||
<filter-class>eu.dnetlib.openaire.usermanagement.utils.CharacterSetFilter</filter-class>
|
||||
</filter>
|
||||
|
||||
<filter-mapping>
|
||||
<filter-name>CharacterSetFilter</filter-name>
|
||||
<url-pattern>/*</url-pattern>
|
||||
</filter-mapping>
|
||||
<servlet>
|
||||
<servlet-name>User API</servlet-name>
|
||||
<servlet-class>com.sun.jersey.spi.spring.container.servlet.SpringServlet</servlet-class>
|
||||
|
|
|
@ -28,7 +28,7 @@
|
|||
<link href="images/favicon/favicon.ico" rel="shortcut icon" type="image/vnd.microsoft.icon" />
|
||||
</head>
|
||||
<body class="" style="">
|
||||
<div class="uk-offcanvas-content uk-height-viewport">Ï
|
||||
<div class="uk-offcanvas-content uk-height-viewport">
|
||||
<!-- MENU STARTS HERE -->
|
||||
<jsp:include page="header.jsp"/>
|
||||
<!-- CONTENT STARTS HERE -->
|
||||
|
|
Loading…
Reference in New Issue