mirror of
https://github.com/e107inc/e107.git
synced 2025-07-11 18:16:21 +02:00
BC fixes for admin-log detail rendering.
This commit is contained in:
@ -680,6 +680,8 @@ if (isset($pref['modules']) && $pref['modules']) {
|
|||||||
}
|
}
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
$sql->db_Mark_Time('Start: Load Plugin Modules');
|
||||||
|
|
||||||
$js_body_onload = array(); // Initialise this array in case a module wants to add to it
|
$js_body_onload = array(); // Initialise this array in case a module wants to add to it
|
||||||
|
|
||||||
// Load e_modules after all the constants, but before the themes, so they can be put to use.
|
// Load e_modules after all the constants, but before the themes, so they can be put to use.
|
||||||
|
@ -548,13 +548,24 @@ class admin_log_form_ui extends e_admin_form_ui
|
|||||||
$text = preg_replace_callback("#\[!(\w+?)(=.+?){0,1}!]#", 'log_process', $curVal);
|
$text = preg_replace_callback("#\[!(\w+?)(=.+?){0,1}!]#", 'log_process', $curVal);
|
||||||
$text = $tp->toHtml($text);
|
$text = $tp->toHtml($text);
|
||||||
|
|
||||||
if(strpos($text,'Array')!==false)
|
if(strpos($text,'Array')!==false || strlen($text)>300)
|
||||||
{
|
{
|
||||||
$id = $this->getController()->getListModel()->get('dblog_id');
|
$id = $this->getController()->getListModel()->get('dblog_id');
|
||||||
$ret ="<a class='e-expandit' href='#".$id."'>Details</a>";
|
$ret ="<a class='e-expandit' href='#".$id."'>Details</a>";
|
||||||
$ret .= "<div class='hide' id='".$id."'>";
|
$ret .= "<div class='hide' id='".$id."'>";
|
||||||
$text = str_replace("<br />","\n",$text);
|
$text = str_replace("<br />","\n",$text);
|
||||||
$text = str_replace("\","/",$text);
|
$text = str_replace("\","/",$text);
|
||||||
|
|
||||||
|
if(substr($text,0,2) == '\n') // cleanup (not sure of the cause)
|
||||||
|
{
|
||||||
|
$text = substr($text,2);
|
||||||
|
}
|
||||||
|
|
||||||
|
if(substr($text,-2) == '\n') // cleanup (not sure of the cause)
|
||||||
|
{
|
||||||
|
$text = substr($text,0,-2);
|
||||||
|
}
|
||||||
|
|
||||||
$text = print_a($text,true);
|
$text = print_a($text,true);
|
||||||
$ret .= $text;
|
$ret .= $text;
|
||||||
$ret .= "</div>";
|
$ret .= "</div>";
|
||||||
|
Reference in New Issue
Block a user