웹 프로젝트에 JpGraph을 사용하려고합니다. 이렇게하려면 내 프로젝트 폴더에 라이브러리를 다운로드하고 다음 테스트 코드를 생성 :JpGraph 작은 데모가 작동하지 않습니다.
<?php
include ("jpgraph-3.5.0b1/src/jpgraph.php");
include ("jpgraph-3.5.0b1/src/jpgraph_gantt.php");
// A new graph with automatic size
$graph = new GanttGraph (0,0, "auto");
// A new activity on row '0'
$activity = new GanttBar (0,"Project", "2001-12-21", "2002-02-20");
$graph->Add($activity);
// Display the Gantt chart
$graph->Stroke();
?>
오류 메시지가 : 내 코드를 잘못 무엇
The image “http://localhost:10088/test/check.php” cannot be displayed,
because it contains errors.
? 사실 here에서 복사되었습니다. 내가 바꾼 유일한 것은 JpGraph 라이브러리에 대한 경로였습니다. 그렇다면이 라이브러리를 프로젝트에 특별한 방식으로 가져와야합니까 (지금까지 JpGraph의 폴더를 프로젝트의 폴더에 복사 했나요?). Zend Studio를 사용하고 있습니다.
그래프의 HTML 스프레드를 살펴보십시오. –
이 코드는 저에게 효과적입니다. 신비한. 포함하고있는 파일의 경로를 다시 확인 했습니까? – octern
@FrederickBehrends HTML 소스가 없습니다. jpgraph는 실제 이미지 파일을 생성합니다. – octern