You need to pass the package the variable name.
<fmt:setBundle basename="com.company.MyPortlet" var="bundle" />
This path is available on the ${bundle} page. You can receive fmt:message messages, and you can use its var attribute to store it in the local area. Then you can use it in the pattern fmt:formatDate attribute fmt:formatDate
<fmt:message bundle="${bundle}" key="company.date.format" var="pattern" /> <fmt:formatDate value="${date}" pattern="${pattern}" />
source share