Skip to content
Snippets Groups Projects
Commit f7142c03 authored by Per Qvarforth's avatar Per Qvarforth
Browse files

heatmap write access

parent 13409389
No related branches found
No related tags found
No related merge requests found
...@@ -206,9 +206,10 @@ sudo a2enmod rewrite ...@@ -206,9 +206,10 @@ sudo a2enmod rewrite
sudo systemctl restart apache2 sudo systemctl restart apache2
``` ```
For the symbols cache to work we need to make sure the webserver has write access to our htdocs/public/symbols directory (the following permission may be a little bit too generous...) For the symbols and heatmap caches to work we need to make sure the webserver has write access (the following permission may be a little bit too generous...)
``` ```
chmod 777 ~/trackdirect/htdocs/public/symbols chmod 777 ~/trackdirect/htdocs/public/symbols
chmod 777 ~/trackdirect/htdocs/public/heatmaps
``` ```
If you have enabled a firewall, make sure port 80 is open. If you have enabled a firewall, make sure port 80 is open.
......
...@@ -77,7 +77,10 @@ $config = array( ...@@ -77,7 +77,10 @@ $config = array(
); );
$heatmap = new gd_heatmap($data, $config); $heatmap = new gd_heatmap($data, $config);
//$heatmap->output();
$heatmap->output($filename); if (is_writable(dirname($filename))) {
readfile($filename); $heatmap->output($filename);
readfile($filename);
} else {
$heatmap->output();
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment