Name
getTags() — テンプレートが使っているタグを返す
説明
string getTags(object template);
この関数は、テンプレートが使っているすべてのタグについて タグ名/属性 のペアの配列を返します。 次のパラメータを使います。
template
はテンプレートオブジェクトです。
Note
この関数は、実験的なものです。
Example 13.22. getTags()
<?php include('Smarty.class.php'); $smarty = new Smarty; // テンプレートオブジェクトを作成します $tpl = $smarty->createTemplate('index.tpl'); // タグを取得します $tags = $smarty->getTags($tpl); print_r($tags); ?>
Comments