jsp java: my tag files don't replace parameters -
script.tag:
<%@ attribute name="file" required="true"%> <script type="text/javascript" src="/path/to/${file}"></script>
my.jsp
<%@ page language="java" contenttype="text/html; charset=utf-8" pageencoding="utf-8"%> <%@ taglib tagdir="/web-inf/tags" prefix="x"%> <x:script file="register.js"/>
however, ${file}
param not replaced , stays literally ${file}
help!
did try adding pagescope when use attribute in tag? this:
<script type="text/javascript" src="/path/to/${pagescope.file}"></script>
Comments
Post a Comment