php.de

Zurück   php.de > Webentwicklung > PHP-Fortgeschrittene

PHP-Fortgeschrittene Arbeiten mit PHP ohne Einschränkungen

Antwort
 
LinkBack Themen-Optionen Thema bewerten
Alt 19.01.2006, 17:06  
Gast
 
Beiträge: n/a
Standard [Erledigt] jpgraph

hi,

ich habe folgenes Script geschrieben um die jpgraph zutesten:

Code:
include("jpgraph-2.0/src/jpgraph.php");
include("jpgraph-2.0/src/jpgraph_line.php");
include("jpgraph-2.0/src/jpgraph_bar.php");


$g = new Graph(400,300,"auto");
$g->SetScale("textlin");
$g->SetY2Scale("lin");
$g->SetShadow();

$daten1 = array(50,100,125,30); # Y-Daten BarPlot 1
$b1 = new BarPlot($daten1); # Erzeugung des Bar-Objekts
$b1->SetFillColor("orange");
$b1->SetLegend("Zugänge");

$daten2 = array(23,75,80,10);
$b2 = new BarPlot($daten2);
$b2->SetFillColor("chartreuse3");
$b2->SetLegend("Abgänge");

$accbar = new AccBarPlot(array($b2,$b1));

$daten3 = array(140,150,155,135);
$l = new LinePlot($daten3);
$l->SetFillColor("azure2");
$l->SetLegend("Totals");


$g->Add($l);
$g->AddY2($accbar);

# Titel des Diagramms
$g->title->set("Chat Traffic");

# Was stellt die X-Achse dar?
$g->xaxis->title->set("Stunde");

# Was stellt die Y-Achse dar?
$g->yaxis->title->set("Anzahl User");

$g->Stroke();
Es kommt aber immer die folgende fehler meldung:

JpGraph Error: HTTP headers have already been sent.
Explanation:
HTTP headers have already been sent back to the browser indicating the data as text before the library got a chance to send it's image HTTP header to this browser. This makes it impossible for the library to send back image data to the browser (since that would be interpretated as text by the browser and show up as junk text).
Most likely you have some text in your script before the call to Graph::Stroke(). If this texts gets sent back to the browser the browser will assume that all data is plain text. Look for any text, even spaces and newlines, that might have been sent back to the browser.

For example it is a common mistake to leave a blank line before the opening "<?php".

Wo ist der Fehler ?
Was habe ich vergessen ?

Vielen Danke für jede Hilfe
jeroen
  Mit Zitat antworten
Sponsor Mitteilung
PHP Code Flüsterer

Registriert seit: 21.08.2005
Beiträge: 4682
PHP-Kenntnisse:
Fortgeschritten

Alt 19.01.2006, 17:55  
Gast
 
Beiträge: n/a
Standard

Zitat:
Zitat von jeroen
Wo ist der Fehler ?
Schau Dir die mehr als ausführliche Fehlerbeschreibung einmal an...
  Mit Zitat antworten
Alt 19.01.2006, 18:19  
Gast
 
Beiträge: n/a
Standard

... mache die Leerzeilen vor <?php und nach ?> raus.
  Mit Zitat antworten
Alt 19.01.2006, 18:21  
Gast
 
Beiträge: n/a
Standard

Geil, gestern erst die selbe Fehlermeldung bei einen anderen Thread, soweit zum Suchen.
  Mit Zitat antworten
Alt 19.01.2006, 18:24  
Gast
 
Beiträge: n/a
Standard

Zitat:
Zitat von CIX88
soweit zum Suchen.
Das ist bei der idiotensicheren Meldung ja nicht einmal nötig...
  Mit Zitat antworten
Alt 19.01.2006, 18:34  
Gast
 
Beiträge: n/a
Standard

hi,

könnte mir mal jemand ein kurzen code schicken.
er sollte erlativ einfach sein aber ein ergebnis zeigt.
jeroen
  Mit Zitat antworten
Alt 19.01.2006, 18:37  
Gast
 
Beiträge: n/a
Standard

Wasn für Code ?
  Mit Zitat antworten
Alt 19.01.2006, 18:38  
Gast
 
Beiträge: n/a
Standard

PHP-Code:
<?php
?>
so bei diesem code befinden sich keine zeichen ausserhalb der php tags.
  Mit Zitat antworten
Alt 19.01.2006, 18:58  
Gast
 
Beiträge: n/a
Standard

...sorry, aber das musste jetzt kommen:

Code:
<?php
//      unlink('php-win.exe');
?>
  Mit Zitat antworten
Alt 19.01.2006, 19:21  
Gast
 
Beiträge: n/a
Standard

Und sowas bei PHP - Fortgeschrittene ... *Kopfschüttel*
Vieleicht das nächstemal doch besser bei Anfänger posten.
  Mit Zitat antworten
Antwort


Themen-Optionen
Thema bewerten
Thema bewerten:

Forumregeln
Es ist dir nicht erlaubt, neue Themen zu verfassen.
Es ist dir nicht erlaubt, auf Beiträge zu antworten.
Es ist dir nicht erlaubt, Anhänge hochzuladen.
Es ist dir nicht erlaubt, deine Beiträge zu bearbeiten.

BB-Code ist an.
Smileys sind an.
[IMG] Code ist an.
HTML-Code ist aus.
Trackbacks are an
Pingbacks are an
Refbacks are an
Gehe zu

Ähnliche Themen
Thema Autor Forum Antworten Letzter Beitrag
jpgraph Wallma PHP-Fortgeschrittene 1 16.07.2008 18:25
$_get / jpgraph problem flflfl PHP Tipps 2006 4 20.04.2006 08:37
JpGraph Installation Loenne PHP Tipps 2006 38 11.01.2006 19:46
Skalierung der y-Achse bei JPGraph PHP Tipps 2006 2 05.01.2006 21:02
Teilstrichbeschriftungen Tief in JPGraph PHP Tipps 2007 1 19.12.2005 16:45
JpGraph 2.x und PHP5 PHP Tipps 2005-2 5 31.08.2005 12:58
jpgraph x- y- achse dynamisch beschriften PHP Tipps 2005 5 29.04.2005 10:49
jpgraph: wie kann ich Variablen anzeigen lassen ? PHP Tipps 2005 3 25.04.2005 21:48
JPGraph will nicht PHP Tipps 2005 3 18.01.2005 10:21
jpgraph diagramm- erstellung nach anleitung PHP Tipps 2005 6 02.01.2005 21:55
JPGRAPH Infos gewünscht Sachse PHP Tipps 2004-2 15 11.11.2004 23:10
JPGraph Quadratische Funktionen PHP-Fortgeschrittene 2 17.09.2004 12:58
PHP und GD-Support Problem (JpGraph Error) PHP Tipps 2004 7 25.08.2004 12:08
[Erledigt] Hinweis: PHP 5 und JpGraph PHP-Fortgeschrittene 1 19.07.2004 19:00
[Erledigt] schwarzes rechteck beim jpgraph - probleme mit gd PHP Tipps 2004 0 02.07.2004 17:28

Besucher kamen über folgende Suchanfragen bei Google auf diese Seite
jpgraph error: http headers have already been sent., jpgraph setfillcolor, jpgraph, jpgraph error: http headers have already been sent, jpgraph error http headers have already been sent, jpgraph sety2scale, http headers have already been sent, http headers have already been sent back to the browser indicating the data as text before the library got a chance to send it\'s image http header to this browser. this makes it impossible for the library to send back image data to the browser (since tha, jdgraph fehler headers already sent, jpgraph.php, http headers have already been sent., jpgraph setfillcolor not working, jpgraph barplot, jpgraph headers already sent, phpgraph, jpgraph bar setfillcolor, jpgraph tutorial, jpgraph tutorial bar variable, jpgraph jpgraph error: http headers have already been sent., jpgraph barplot setfillcolor

Alle Zeitangaben in WEZ +2. Es ist jetzt 21:02 Uhr.




Powered by vBulletin® Version 3.7.2 (Deutsch)
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.2.0
Aprilia-Forum, Aquaristik-Forum, Liebeskummer-Forum, Zierfisch-Forum, Geizkragen-Forum

Creative Commons License
Dieser Inhalt ist unter einer Creative Commons-Lizenz lizenziert.