変数の値を出力します。
変数が配列の場合は、ARRAY_DELIMITER で区切って要素名を指定します。
'!{{' と '}}!' で囲われた文字列は、タグとして解釈せずそのまま出力されます。
{{ val_name }}
$assign['sample_echo1'] = 'default escape ( \' " < > & )';
$assign['sample_echo2'] = 'not escape ( \' " < > & )';
$assign['sample_echo3'] = 'http://example.com/';
$assign['sample_echo4'] = 'http://example.com/';
$assign['sample_echo5'] = "Line1
Line2 In PHP you write like \"\n\" instead of '\n'";
$assign['sample_echo6'] = array('key of array is numeric', 'In multidimensional array, separate element names with const::ARRAY_DELIMITER');
$assign['sample_echo7']['a7'] = 'key of array is string';
$assign['sample_echo8'] = "');alert(document.location+'";
$assign['sample_echo9'] = "s a m p l e";
$assign['sample_echo10'] = "ssa mple";
$assign['is'] = "dummy";
{{ sample_echo1 }}<br>
{{ sample_echo2|raw }}<br>
{{ sample_echo3|url }}<br>
{{ sample_echo4|urlpathinfo }}<br>
{{ sample_echo5|nl2br }}<br>
{{ sample_echo6.0 }} {{ sample_echo6.1 }}<br>
{{ sample_echo7.a7 }}<br>
JavaScript escape (alert as a string) :<input type="button" value="echo 8" onclick="javascript:alert('{{ sample_echo8|js }}');"><br>
HTML escape (alert as document.location):<input type="button" value="echo 8" onclick="javascript:alert('{{ sample_echo8|html }}');"><br>
{{ sample_echo9|nbsp }}<br>
{{ sample_echo10|tab2nbsp }}<br>
!{{ this {{ is }} literal }}!<br>
default escape ( ' " < > & )
not escape ( ' " < > & )
http%3A%2F%2Fexample.com%2F
http%3A//example.com/
Line1
Line2 In PHP you write like "\n" instead of '\n'
key of array is numeric In multidimensional array, separate element names with const::ARRAY_DELIMITER
key of array is string
JavaScript escape (alert as a string) :
HTML escape (alert as document.location) :
s a m p l e
ssa mple
this {{ is }} literal