Escape apostrophe as \' with c:out JSP
问题 I have an object field with person's last name. If I use ${person.lastName} , I get O'Brian If I use <c:out value="${person.lastName}"/> I get O'Brian Both outputs breaks the next jsp code in IE <a href="#" class="delete" onclick="if(confirm('<c:out value="${application.lastName}"/> ' + _('Are you sure you want to delete this application?'))) {deleteApplication('${application.identifier}')};return false;"><bean:message key="application.delete"/></a> because it gets transformed to onclick="if