Jak używać z metką?
Czy mogę użyć <spring:url value="/something" />
wewnątrz znacznika <a>
?
31
1 answers
<spring:url value="/something" var="url" htmlEscape="true"/>
<a href="${url}">...</a>
Ale ty też używasz c: url
<c:url value="/something" var="url"/>
<a href="<c:out value='${url}'/>">...</a>
Jedyną ważną różnicą między c:url
i spring:url
jest to, że c:url
nie koduje HTML utworzonego adresu url. Ale dla poprawnego adresu URL {[5] } pomiędzy parametrami adresu url musi być &
. Więc potrzebujesz c:out
, aby temu uciec. -- W spring:url
masz już tę funkcjonalność (jeśli Rozumiem dokumentację poprawne).
Przestrzenie nazw:
xmlns:spring="http://www.springframework.org/tags"
xmlns:c="http://java.sun.com/jsp/jstl/core"
56
Author: Ralph,
Warning: date(): Invalid date.timezone value 'Europe/Kyiv', we selected the timezone 'UTC' for now. in /var/www/agent_stack/data/www/doraprojects.net/template/agent.layouts/content.php on line 54
2014-07-21 20:31:10
Warning: date(): Invalid date.timezone value 'Europe/Kyiv', we selected the timezone 'UTC' for now. in /var/www/agent_stack/data/www/doraprojects.net/template/agent.layouts/content.php on line 54
2014-07-21 20:31:10