Vheissu / Ci-Smarty

Smarty templating engine integration for Codeigniter 3.0+ with inbuilt theming and asset management.
http://ilikekillnerds.com
179 stars 43 forks source link

Error reporting #14

Closed viralganatra closed 12 years ago

viralganatra commented 12 years ago

Error reporting doesn't appear to work properly. In the config I have set error reporting to:

$config['template_error_reporting'] = "E_ALL ^ E_NOTICE";

so that any notices don't show up. However in the CI log files it seem to interpret it as an error? E.g:

ERROR - 2011-12-02 21:00:54 --> Severity: Notice --> Undefined index: foo \cache\smarty\compiled\b45265bb89040a86b3bc4d30ea7ca5c612acb525.file.bar.tpl.php 55

I can't work out how to stop these appearing, any ideas?

I'd rather not have to go through every variable and do {if isset($foo)}

Thanks

Vheissu commented 12 years ago

Sorry about the delayed response, I've had other work commitments. I'm going to take a look at this ASAP.

Vheissu commented 12 years ago

Had a look and I think it is because error values are not meant to be within quotes, like they're meant to be CONSTANT values, so no quotes around the error setting. I made a commit without the quotes and no errors from initial testing have appeared. Try that and let me know how it goes.

viralganatra commented 12 years ago

Sorry still have the same issue :(

haider-pw commented 10 years ago

Same here. $config['template_error_reporting'] = E_ALL & ~E_NOTICE; if there is any error in template, then smarty don't show the error.