| 1 | <html xmlns:tal="http://purl.org/petal/1.0/"> |
| 2 | <body> |
| 3 | <p> |
| 4 | <!--? Loop through hash keys/values using 'Each' --> |
| 5 | <ul> |
| 6 | <li tal:repeat="item each: $each_hash_ref"><span tal:replace="item/key">key</span> => <span tal:replace="item/val">value</span></li> |
| 7 | </ul> |
| 8 | |
| 9 | <!--? Loop through hash keys using 'Keys'--> |
| 10 | <ul> |
| 11 | <!--? NOTE: Petal can't do dynamic keys, so the values shouldn't appear here: --> |
| 12 | <li tal:repeat="key keys: $keys_hash_ref"><span tal:replace="key">key</span> => <span tal:replace="keys_hash_ref/$key">value</span></li> |
| 13 | </ul> |
| 14 | </p> |
| 15 | </body> |
| 16 | </html> |
| 17 |