aboutsummaryrefslogtreecommitdiffstats
path: root/config/sarg
diff options
context:
space:
mode:
Diffstat (limited to 'config/sarg')
-rw-r--r--config/sarg/sarg.inc2
-rwxr-xr-xconfig/sarg/sarg_frame.php2
-rwxr-xr-xconfig/sarg/sarg_reports.php2
3 files changed, 5 insertions, 1 deletions
diff --git a/config/sarg/sarg.inc b/config/sarg/sarg.inc
index 0a66137b..59b7eb11 100644
--- a/config/sarg/sarg.inc
+++ b/config/sarg/sarg.inc
@@ -260,7 +260,7 @@ function sync_package_sarg() {
$anonymous_output_files=(preg_match('/anonymous_output_files/',$sarg['report_options'])?"yes":"no");
$resolve_ip=(preg_match('/resolve_ip/',$sarg['report_options'])?"yes":"no");
$user_ip=(preg_match('/user_ip/',$sarg['report_options'])?"yes":"no");
- $sort_order=(preg_match('/user_sort_field_order/',$sarg['report_options'])?"REVERSE":"NORMAL");
+ $sort_order=(preg_match('/user_sort_field_order/',$sarg['report_options'])?"reverse":"normal");
$remove_temp_files=(preg_match('/remove_temp_files/',$sarg['report_options'])?"yes":"no");
$main_index=(preg_match('/main_index/',$sarg['report_options'])?"yes":"no");
$index_tree=(preg_match('/index_tree/',$sarg['report_options'])?"file":"date");
diff --git a/config/sarg/sarg_frame.php b/config/sarg/sarg_frame.php
index 4d3421ab..21638247 100755
--- a/config/sarg/sarg_frame.php
+++ b/config/sarg/sarg_frame.php
@@ -68,9 +68,11 @@ if ($report != "" )
#look for graph files inside reports.
if (preg_match_all('/img src="([a-zA-Z0-9._-]+).png/',$report,$images)){
+ conf_mount_rw();
for ($x=0;$x<count($images[1]);$x++){
copy("{$dir}/{$prefix}/{$images[1][$x]}.png","/usr/local/www/sarg-images/temp/{$images[1][$x]}.{$rand}.png");
}
+ conf_mount_ro();
}
print preg_replace($pattern,$replace,$report);
}
diff --git a/config/sarg/sarg_reports.php b/config/sarg/sarg_reports.php
index b1792312..b156a4d7 100755
--- a/config/sarg/sarg_reports.php
+++ b/config/sarg/sarg_reports.php
@@ -61,7 +61,9 @@ require("guiconfig.inc");
$tab_array[] = array(gettext("XMLRPC Sync"), false, "/pkg_edit.php?xml=sarg_sync.xml&id=0");
$tab_array[] = array(gettext("Help"), false, "/pkg_edit.php?xml=sarg_about.php");
display_top_tabs($tab_array);
+ conf_mount_rw();
exec('rm -f /usr/local/www/sarg-images/temp/*');
+ conf_mount_ro();
?>
</td></tr>
<tr>