So, nachdem ich anders auch nicht weiterkomme werde ich mich mal ans debuggen machen. Gar nicht so einfach, da ich von php nicht wirklich viel Ahnung habe.
Als erstes habe ich mal geschaut ob überhaupt das Script aufgerufen wird. Ich habe mir aus dem Quelltext folgende Zeile herausgefischt:
/bug/plugin.php?page=MantisGraph/summary_graph_bystatus_pct.php&width=450
und direkt in den Browser eingegeben.
Fehlermeldung erhalte ich dann noch keine, wie zu erwarten funktionierte es jedoch auch nicht.
Dann habe ich auf dem Server die Datei
C:\Server\mantisbt\plugins\MantisGraph\pages\summary_graph_bystatus_pct.php
manipuliert:
Code: Select all
<?php
# MantisBT - a php based bugtracking system
# MantisBT is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 2 of the License, or
# (at your option) any later version.
#
# MantisBT is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with MantisBT. If not, see <http://www.gnu.org/licenses/>.
/**
* @package MantisBT
* @copyright Copyright (C) 2000 - 2002 Kenzaburo Ito - kenito@300baud.org
* @copyright Copyright (C) 2002 - 2010 MantisBT Team - mantisbt-dev@lists.sourceforge.net
* @link http://www.mantisbt.org
*/
/**
* MantisBT Core API's
*/
require_once( 'core.php' );
require_once( 'graph_api.php' );
access_ensure_project_level( config_get( 'view_summary_threshold' ) );
$f_width = gpc_get_int( 'width', 300 );
$t_token = token_get_value( TOKEN_GRAPH );
if ( $t_token == null ) {
$t_metrics = create_bug_enum_summary( lang_get( 'status_enum_string' ), 'status' );
} else {
$t_metrics = unserialize( $t_token );
}
graph_pie( $t_metrics, plugin_lang_get( 'by_status_pct' ), $f_width, $f_width );
error_log("Testausgabe");
Es sollte also einfach nun der String "Testausgabe" in der error.log auftauchen. Und das passiert auch. Ich kann sicher sagen, dass das Script ausgeführt wird. Jetzt weis ich jedoch nicht wie ich am besten weitermache. Hat dazu jemand eine Idee?
Kann man vieleicht irgendwie unterscheiden, ob die Grafik nicht generriert wird oder einfach über Apache nicht ausgeliefert wird?
Kann man die erzeugte Grafik einfach in eine Datei auf dem Server abspeichern?