lukaszlenart commented on a change in pull request #520:
URL: https://github.com/apache/struts/pull/520#discussion_r775783019



##########
File path: 
apps/rest-showcase/src/main/webapp/WEB-INF/content/orders-deleteConfirm.jsp
##########
@@ -27,8 +27,10 @@
     <meta http-equiv="X-UA-Compatible" content="IE=edge">
     <meta name="viewport" content="width=device-width, initial-scale=1">
     <title>Orders</title>
-    <s:link href="${pageContext.request.contextPath}/css/bootstrap.min.css" 
rel="stylesheet"></s:link>
-    <s:link href="${pageContext.request.contextPath}/css/app.css" 
rel="stylesheet"></s:link>
+    <!-- Using a standard HTML link tag with JSP EL to get the contextPath may 
be simpler, but this is an equivalent for s:link -->
+    <s:set 
var="pageContextPath"><%=((HttpServletRequest)request).getContextPath()%></s:set>
+    <s:link href="%{#pageContextPath}/css/bootstrap.min.css" 
rel="stylesheet"></s:link>

Review comment:
       I think this should work as well:
   ```
   <s:link href="%{#request.pageContext}/css/bootstrap.min.css" 
rel="stylesheet"></s:link>
   ```
   and it's more [Struts'ish](https://struts.apache.org/tag-developers/ognl)




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to