Announcement Announcement Module
Collapse
No announcement yet.
Velocity and properties files Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • Velocity and properties files

    Hi,
    I have a spring portlet application and I want to be able to access a propeties file in my velocity file to display and format messages.
    In a jsp file I would use
    Code:
    <fmt:setBundle basename="bundleName" />
    to set the name of the properties file to look for, and then either
    Code:
    <fmt:message key="property"><fmt:param>${param}</fmt:param></fmt:message>
    or
    Code:
    <fmt:message key="property" />
    to display it, depending on whether it needed parameters or not.

    I was wondering if there's a way to do this in velocity, hopefully using spring?
    I read something about #springMessage('key') but couldn't find how to set the properties file or how to pass parameters to it...

    Any help would be much appreciated.
    Thanks
Working...
X