I am trying to build out a table of values. I would like the user to be
able to choose which columns are visible, and to re-order them (not
interactively, on a separate page). My initial method for implementing
this looks something like:

User preferences:
<column title="i18n.property.prop1">property1</column>
<column title="i18n.property.prop2">property2</column>
...

And then something like this for displaying:
<table>
        <tr>
                <s:iterator value="prefs">
                        <th><s:text name="content" /></th>
                </s:iterator>
        </tr>

        <s:iterator value="rows">
                <tr>
                        <s:iterator value="prefs">
                                <td><s:property
value="%{getAttribute('title')}" /></td>
                        </s:iterator>
                </tr>
        </s:iterator>
</table>

But I'm not sure how to do a double-indirection.
%{getAttribute('title')} is going to return something like "property1"
or "property2", but what I really want is to have OGNL go back out and
retrieve the value associated with that name, as if I had typed
'<s:property value="property1" />'. Is there a way to do this?

Jonathan P. Pearson - Software Engineer
-------------------------------------------------- 
SIXNET - Solutions for Your Industrial Networking Challenges
331 Ushers Road, Ballston Lake, NY 12019
Tel: 1.518.877.5173, Fax: 1.518.877.8346
www.sixnet.com

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscr...@struts.apache.org
For additional commands, e-mail: user-h...@struts.apache.org

Reply via email to