X-Git-Url: https://jasonwoof.com/gitweb/?p=wfpl.git;a=blobdiff_plain;f=dwt.php;h=b4b821e20db5a99da85cc0e66c6c76e5a2bc624b;hp=d3477534fa964fe605732647be5b48b148c1ce4d;hb=HEAD;hpb=883f464e943d1588c0c4227d7f6e69dedb7b6a21 diff --git a/dwt.php b/dwt.php index d347753..b4b821e 100644 --- a/dwt.php +++ b/dwt.php @@ -1,24 +1,11 @@ '); @@ -97,11 +84,22 @@ function dwt_prepend($name, $value) { dwt_prepend_raw("", $value); } +function dwt_get_raw($name) { + $index = dwt_find_raw($name); + if($index !== null) { + return $GLOBALS['_dwt_values'][$index]; + } else { + return false; + } +} + +function dwt_get($name) { + return dwt_get_raw(""); +} + function dwt_output($filename = null) { if($filename !== null) { dwt_load($filename); } print(str_replace($GLOBALS['_dwt_keys'], $GLOBALS['_dwt_values'], $GLOBALS['_dwt_template'])); } - -?>