| 148 |
lars |
1 |
\$debugging\_ctrl {#variable.debugging.ctrl}
|
|
|
2 |
=================
|
|
|
3 |
|
|
|
4 |
This allows alternate ways to enable debugging. `NONE` means no
|
|
|
5 |
alternate methods are allowed. `URL` means when the keyword
|
|
|
6 |
`SMARTY_DEBUG` is found in the `QUERY_STRING`, debugging is enabled for
|
|
|
7 |
that invocation of the script. If [`$debugging`](#variable.debugging) is
|
|
|
8 |
TRUE, this value is ignored.
|
|
|
9 |
|
|
|
10 |
|
|
|
11 |
<?php
|
|
|
12 |
// shows debug console only on localhost ie
|
|
|
13 |
// http://localhost/script.php?foo=bar&SMARTY_DEBUG
|
|
|
14 |
$smarty->debugging = false; // the default
|
|
|
15 |
$smarty->debugging_ctrl = ($_SERVER['SERVER_NAME'] == 'localhost') ? 'URL' : 'NONE';
|
|
|
16 |
?>
|
|
|
17 |
|
|
|
18 |
See also [debugging console](#chapter.debugging.console) section,
|
|
|
19 |
[`$debugging`](#variable.debugging) and
|
|
|
20 |
[`$smarty_debug_id`](#variable.smarty.debug.id).
|