Skip to content
Permalink
Browse files

for set in hash.item

  • Loading branch information...
fayland committed May 24, 2013
1 parent a5f4181 commit ad9f8d40e903a99c0f2e0aac640ee81cc949911f
Showing with 5 additions and 0 deletions.
  1. +1 −0 Template.pod
  2. +4 −0 xt/template_hash_set.tt2
@@ -97,6 +97,7 @@ CALL 与 GET 相似但不输出任何东西(忽略返回结果)。
=item * Hash 的键里含有特殊符号或者空格

[% feed.item('openSearch:totalResults') %]
[% hash.item("space stuff") = "space value"; %]

当键里含有特殊符号如 ':' 时,可以使用 item 来获取值。参考 L<Template::Manual::VMethods>

@@ -0,0 +1,4 @@
[% hash = {};
hash.item("space stuff") = "space value"; %]

HASH "space stuff" = [% hash.item("space stuff") %]

0 comments on commit ad9f8d4

Please sign in to comment.
You can’t perform that action at this time.