help files
Z505 | PasWiki | FUQ | Search | Main Docs | API Guide



[Overview][Constants][Procedures and functions] Reference for unit 'pwumain' (#powtils_main)

TemplateRaw

Declaration

Source position: pwumain.pas line 147

function TemplateRaw(

  const fname: String

):errcode;

Notes

Outputs a file with embedded $MacroVars. It is similar to TemplateOut, but this function let's raw HTML and malicious characters output to the browser. Use this only if TemplateOut is restricting you from displaying certain characters that are normally malicious.

Bugs

Versions 1.6.0.2 and previous contained a small bug and this function acted the same as TemplateOut. See the fix.

Return Code

A warning will be shown in the web browser if the file was missing or there was a problem. The function also returns FILE_READ_ERR if not found, or OK if everything went okay.

Tips

In older versions such as 1.5 and 1.6.0.0 this function did not return a status code, it just threw a polite warning to the screen. In versions 1.6.0.1 and above, return codes are available in addition to a warning shown (if warnings are on in your pwu config file). Having these options allows flexibility.






lufdoc, Powtils, fpc, freepascal, delphi, kylix, c/c++, mysql, cgi web framework docs, Z505