Skip to content

Instantly share code, notes, and snippets.

@avernet
Created April 13, 2010 02:00
Show Gist options
  • Save avernet/364238 to your computer and use it in GitHub Desktop.
Save avernet/364238 to your computer and use it in GitHub Desktop.
<!--
Copyright (C) 2009 Orbeon, Inc.
This program is free software; you can redistribute it and/or modify it under the terms of the
GNU Lesser General Public License as published by the Free Software Foundation; either version
2.1 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
See the GNU Lesser General Public License for more details.
The full text of the license is available at http://www.gnu.org/copyleft/lesser.html
-->
<html xmlns:xf="http://www.w3.org/2002/xforms" xmlns:f="http://orbeon.org/oxf/xml/formatting" xmlns="http://www.w3.org/1999/xhtml"
xmlns:xhtml="http://www.w3.org/1999/xhtml" xmlns:xxforms="http://orbeon.org/oxf/xml/xforms" xmlns:fr="http://orbeon.org/oxf/xml/form-runner"
xmlns:ev="http://www.w3.org/2001/xml-events" xmlns:xs="http://www.w3.org/2001/XMLSchema">
<head>
<title>Using YUI's datatable</title>
<xf:model id="model">
<xf:instance id="instance">
<instance xmlns="">
</instance>
</xf:instance>
<xf:instance id="template">
<record xmlns="">
<AAA>1</AAA>
<BBB>foo</BBB>
<CCC>bar</CCC>
</record>
</xf:instance>
</xf:model>
</head>
<body>
<xf:trigger>
<xf:label>Add</xf:label>
<xf:insert ev:event="DOMActivate" context="." origin="instance('template')"/>
</xf:trigger>
<fr:datatable id="table-repeat1" width="100%" height="250px" scrollable="both">
<thead>
<tr>
<th fr:sortable="true" fr:resizeable="true">AAA (s)</th>
<th fr:sortable="true" fr:resizeable="true">BBB (s)</th>
<th>CCC</th>
</tr>
</thead>
<tbody>
<tr repeat-nodeset="record">
<td>
<xf:output ref="AAA"/>
</td>
<td>
<xf:output ref="BBB"/>
</td>
<td>
<xf:output ref="CCC"/>
</td>
</tr>
</tbody>
</fr:datatable>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment