}
# Check if the config file exists
-if (!-r $config{'webalizer_conf'} && -r $config{'alt_conf'}) {
- # No, but the sample one does
- system("cp '$config{'alt_conf'}' '$config{'webalizer_conf'}' >/dev/null 2>&1");
- }
if (!-r $config{'webalizer_conf'}) {
&main_header();
print &text('index_econf', "<tt>$config{'webalizer_conf'}</tt>",
$custom_logs_file = "$module_config_directory/custom-logs";
%access = &get_module_acl();
+# Use sample config if needed
+if (!-r $config{'webalizer_conf'} && -r $config{'alt_conf'}) {
+ ©_source_dest($config{'alt_conf'}, $config{'webalizer_conf'});
+ }
+
# get_config([logfile])
# Parse the webalizer config file for a single logfile or global
sub get_config