]>
src.bluestatic.org Git - bugdar.git/blob - showhistory.php
2 /*=====================================================================*\
3 || ################################################################### ||
4 || # BugStrike [#]version[#]
5 || # --------------------------------------------------------------- # ||
6 || # Copyright ©2002-[#]year[#] by Iris Studios, Inc. All Rights Reserved. # ||
7 || # This file may not be reproduced in any way without permission. # ||
8 || # --------------------------------------------------------------- # ||
9 || # User License Agreement at http://www.iris-studios.com/license/ # ||
10 || ################################################################### ||
11 \*=====================================================================*/
13 $fetchtemplates = array (
18 require_once ( './global.php' );
20 $bug = $db- > query_first ( "SELECT * FROM " . TABLE_PREFIX
. "bug WHERE bugid = " . intval ( $bugsys- > in
[ 'bugid' ]));
23 echo 'alert: bad bug' ;
27 // ###################################################################
29 $logs = $db- > query ( "SELECT history.*, user.* FROM " . TABLE_PREFIX
. "history LEFT JOIN " . TABLE_PREFIX
. "user AS user ON (user.userid = history.userid) WHERE bugid = $bug [bugid]" );
30 while ( $log = $db- > fetch_array ( $logs ))
32 $log [ 'formatted' ] = call_user_func_array ( 'phrase' , array_merge ( array ( $log [ 'language' ]), unserialize ( $log [ 'arguments' ])));
33 $log [ 'date' ] = datelike ( 'standard' , $log [ 'dateline' ]);
34 $log [ 'user' ] = construct_user_display ( $log );
36 $log [ 'initial' ] = unserialize ( $log [ 'original' ]);
37 $log [ 'final' ] = unserialize ( $log [ 'changed' ]);
39 foreach ( $log [ 'initial' ] AS $key => $value )
41 $log [ 'changes' ] .= "[ $key ] \" $value\" => \"{ $log['final'][$key]} \"\n " ;
44 eval ( ' $history .= "' . $template- > fetch ( 'history_bit' ) . '";' );
47 eval ( ' $template- >flush("' . $template- > fetch ( 'history' ) . '");' );
49 /*=====================================================================*\
50 || ###################################################################
53 || ###################################################################
54 \*=====================================================================*/