diff options
author | brettp <brettp@36083f99-b078-4883-b0ff-0f9b5a30f544> | 2009-10-16 20:26:12 +0000 |
---|---|---|
committer | brettp <brettp@36083f99-b078-4883-b0ff-0f9b5a30f544> | 2009-10-16 20:26:12 +0000 |
commit | c66831fa5138a277a9729174caf14c7eb323fb07 (patch) | |
tree | 2444b54badf4914b59c88700cc1ce30a57ae7ff1 /views/default/messages/exceptions | |
parent | 8048313e87b9fd5ab6734e29a0e951524fa33e45 (diff) | |
download | elgg-c66831fa5138a277a9729174caf14c7eb323fb07.tar.gz elgg-c66831fa5138a277a9729174caf14c7eb323fb07.tar.bz2 |
Standardizing views.`
git-svn-id: http://code.elgg.org/elgg/trunk@3555 36083f99-b078-4883-b0ff-0f9b5a30f544
Diffstat (limited to 'views/default/messages/exceptions')
-rw-r--r-- | views/default/messages/exceptions/exception.php | 67 |
1 files changed, 31 insertions, 36 deletions
diff --git a/views/default/messages/exceptions/exception.php b/views/default/messages/exceptions/exception.php index 0b482d845..c93883cbc 100644 --- a/views/default/messages/exceptions/exception.php +++ b/views/default/messages/exceptions/exception.php @@ -1,44 +1,39 @@ <?php +/** + * Elgg exception + * Displays a single exception + * + * @package Elgg + * @subpackage Core + * @author Curverider Ltd + * @link http://elgg.org/ + * + * @uses $vars['object'] An exception + */ - /** - * Elgg exception - * Displays a single exception - * - * @package Elgg - * @subpackage Core +global $CONFIG; - * @author Curverider Ltd +$class = get_class($vars['object']); +$message = elgg_view('output/longtext', array('value' => $vars['object']->getMessage())); - * @link http://elgg.org/ - * - * @uses $vars['object'] An exception - */ +$body = <<< END +<p class="messages-exception"> + <span title="$class"> + <b>$message</b> + </span> +</p> +END; - global $CONFIG; - - $class = get_class($vars['object']); - $message = elgg_view('output/longtext', array('value' => $vars['object']->getMessage())); - - $body = <<< END - <p class="messages-exception"> - <span title="$class"> - <b>$message</b> - </span> +if ($CONFIG->debug) { + $details = elgg_view('output/longtext', array('value' => htmlentities(print_r($vars['object'], true), ENT_QUOTES, 'UTF-8'))); + $body .= <<< END + <hr /> + <p class="messages-exception-detail"> + $details </p> END; +} - if ($CONFIG->debug) - { - $details = elgg_view('output/longtext', array('value' => htmlentities(print_r($vars['object'], true), ENT_QUOTES, 'UTF-8'))); - $body .= <<< END - <hr /> - <p class="messages-exception-detail"> - $details - </p> -END; - } - - $title = $class; - - echo elgg_view_layout("one_column", elgg_view_title($title) . $body); -?>
\ No newline at end of file +$title = $class; + +echo elgg_view_layout("one_column", elgg_view_title($title) . $body);
\ No newline at end of file |