summaryrefslogtreecommitdiffstats
path: root/library/Pbs/Graph.php
diff options
context:
space:
mode:
Diffstat (limited to 'library/Pbs/Graph.php')
-rw-r--r--library/Pbs/Graph.php10
1 files changed, 8 insertions, 2 deletions
diff --git a/library/Pbs/Graph.php b/library/Pbs/Graph.php
index 7711dce..ae3ab16 100644
--- a/library/Pbs/Graph.php
+++ b/library/Pbs/Graph.php
@@ -18,8 +18,14 @@ class Pbs_Graph{
$this->getParentGroups($groupID);
$this->getChildGroups($groupID);
$this->graphstring .= '}';
- $this->graphstring = str_replace(array("\t","\n"),"",$this->graphstring);
- return str_replace('"','\"',$this->graphstring);
+ $this->graphstring = str_replace(array("\t","\n"),"",$this->graphstring);
+ $this->graphstring = str_replace('"','\"',$this->graphstring);
+
+ $str = 'echo "';
+ $str .= $this->graphstring;
+ $str .= '" | dot -Tpng ';
+ passthru($str,$end);
+ return $end;
}
private function getGroupTitle($groupID){
$group = new Application_Model_Group();