• Main Page
  • Related Pages
  • Namespaces
  • Data Structures
  • Files
  • Examples
  • File List

E:/E/GEAMP/www/openbiz/openbiz/others/Smarty/libs/internals/core.display_debug_console.php

00001 <?php
00017 function smarty_core_display_debug_console($params, &$smarty)
00018 {
00019     // we must force compile the debug template in case the environment
00020     // changed between separate applications.
00021 
00022     if(empty($smarty->debug_tpl)) {
00023         // set path to debug template from SMARTY_DIR
00024         $smarty->debug_tpl = SMARTY_DIR . 'debug.tpl';
00025         if($smarty->security && is_file($smarty->debug_tpl)) {
00026             $smarty->secure_dir[] = realpath($smarty->debug_tpl);
00027         }
00028         $smarty->debug_tpl = 'file:' . SMARTY_DIR . 'debug.tpl';
00029     }
00030 
00031     $_ldelim_orig = $smarty->left_delimiter;
00032     $_rdelim_orig = $smarty->right_delimiter;
00033 
00034     $smarty->left_delimiter = '{';
00035     $smarty->right_delimiter = '}';
00036 
00037     $_compile_id_orig = $smarty->_compile_id;
00038     $smarty->_compile_id = null;
00039 
00040     $_compile_path = $smarty->_get_compile_path($smarty->debug_tpl);
00041     if ($smarty->_compile_resource($smarty->debug_tpl, $_compile_path))
00042     {
00043         ob_start();
00044         $smarty->_include($_compile_path);
00045         $_results = ob_get_contents();
00046         ob_end_clean();
00047     } else {
00048         $_results = '';
00049     }
00050 
00051     $smarty->_compile_id = $_compile_id_orig;
00052 
00053     $smarty->left_delimiter = $_ldelim_orig;
00054     $smarty->right_delimiter = $_rdelim_orig;
00055 
00056     return $_results;
00057 }
00058 
00059 /* vim: set expandtab: */
00060 
00061 ?>

Generated on Thu Apr 19 2012 17:01:16 for openbiz by  doxygen 1.7.2