diff --git a/WebminUI/File.pm b/WebminUI/File.pm index c9a5f29d1..337c989d2 100644 --- a/WebminUI/File.pm +++ b/WebminUI/File.pm @@ -29,7 +29,7 @@ my $name = $self->get_name(); my $directory = $self->get_directory(); my $add = 0; my $chroot = $self->get_chroot(); -$rv .= "\n"; +$rv .= "\n"; return $rv; } diff --git a/WebminUI/Group.pm b/WebminUI/Group.pm index 04aeb4da5..56eed5225 100644 --- a/WebminUI/Group.pm +++ b/WebminUI/Group.pm @@ -28,7 +28,7 @@ my $rv = WebminUI::Textbox::html($self); my $name = $self->get_name(); my $multiple = $self->get_multiple(); local $w = $multiple ? 500 : 300; -$rv .= " \n"; +$rv .= " \n"; return $rv; } diff --git a/WebminUI/Table.pm b/WebminUI/Table.pm index 12f4cb83e..9c26f18d8 100644 --- a/WebminUI/Table.pm +++ b/WebminUI/Table.pm @@ -162,14 +162,14 @@ foreach my $h (@{$self->get_headings()}) { # Not sorting on this column .. show grey button my $url = $self->make_url($i, 0, undef, undef); $hh .= "". - ""; + ""; } else { # Sorting .. show button to switch mode my $notsort = !$sortdir; my $url = $self->make_url($i, $sortdir ? 0 : 1, undef, undef); $hh .= "". - ""; + ""; } $hh .= ""; push(@sheadings, $hh); @@ -218,27 +218,27 @@ if ($self->get_paging() && $origsize) { if ($page != 0) { # Add start and left arrows my $surl = $self->make_url(undef, undef, undef, 0); - $rv .= "\n"; + $rv .= "\n"; my $lurl = $self->make_url(undef, undef, undef, $page-1); - $rv .= "\n"; + $rv .= "\n"; } else { # Start and left are disabled - $rv .= "\n"; - $rv .= "\n"; + $rv .= "\n"; + $rv .= "\n"; } $rv .= &text('ui_paging', $start+1, $end+1, $origsize); if ($end < $origsize-1) { # Add right and end arrows my $rurl = $self->make_url(undef, undef, undef, $page+1); - $rv .= "\n"; + $rv .= "\n"; my $eurl = $self->make_url(undef, undef, undef, $lastpage); - $rv .= "\n"; + $rv .= "\n"; } else { # Right and end are disabled - $rv .= "\n"; - $rv .= "\n"; + $rv .= "\n"; + $rv .= "\n"; } $rv .= "\n"; } diff --git a/WebminUI/User.pm b/WebminUI/User.pm index 500550435..25f7e1dbe 100644 --- a/WebminUI/User.pm +++ b/WebminUI/User.pm @@ -28,7 +28,7 @@ my $rv = WebminUI::Textbox::html($self); my $name = $self->get_name(); my $multiple = $self->get_multiple(); local $w = $multiple ? 500 : 300; -$rv .= " \n"; +$rv .= " \n"; return $rv; } diff --git a/adsl-client/index.cgi b/adsl-client/index.cgi index e1b7656fe..7e27bb3fa 100755 --- a/adsl-client/index.cgi +++ b/adsl-client/index.cgi @@ -13,7 +13,7 @@ $vers = &get_pppoe_version(\$out); if (!$vers) { # Not installed print "

",&text('index_eadsl', "$config{'pppoe_cmd'}", - "$gconfig{'webprefix'}/config.cgi?$module_name"),"

\n"; + "@{[&get_webprefix()]}/config.cgi?$module_name"),"

\n"; } elsif (!($conf = &get_config())) { # Missing config file @@ -21,7 +21,7 @@ elsif (!($conf = &get_config())) { # Just give up print "

", &text('index_econfig', "$config{'pppoe_conf'}", - "$gconfig{'webprefix'}/config.cgi?$module_name"),"

\n"; + "@{[&get_webprefix()]}/config.cgi?$module_name"),"

\n"; } else { # On redhat systems, the file needs to be created by this @@ -37,7 +37,7 @@ elsif (&find("TYPE", $conf) =~ /modem/i) { # For a modem on a redhat system $config{'pppoe_conf'} =~ /^(.*)\//; print "

",&text('index_emodem', "$1", - "$gconfig{'webprefix'}/config.cgi?$module_name"),"

\n"; + "@{[&get_webprefix()]}/config.cgi?$module_name"),"

\n"; } else { # Show configuration form diff --git a/ajaxterm/index.cgi b/ajaxterm/index.cgi index cbe3ac731..b8b8fe024 100755 --- a/ajaxterm/index.cgi +++ b/ajaxterm/index.cgi @@ -73,7 +73,7 @@ use warnings; # Show the iframe print "

\n"; -print "
\n"; print "

\n"; print &text('index_credits', 'http://antony.lesuisse.org/software/ajaxterm/'), diff --git a/apache/index.cgi b/apache/index.cgi index 2d85d1b18..e5c896e89 100755 --- a/apache/index.cgi +++ b/apache/index.cgi @@ -10,7 +10,7 @@ require './apache-lib.pl'; if (!($httpd = &find_httpd())) { &ui_print_header(undef, $text{'index_title'}, "", undef, 1, 1); print &text('index_eserver', "$config{'httpd_path'}", - "$gconfig{'webprefix'}/config.cgi?$module_name"),"

\n"; + "@{[&get_webprefix()]}/config.cgi?$module_name"),"

\n"; &foreign_require("software", "software-lib.pl"); $lnk = &software::missing_install_link("apache", $text{'index_apache'}, "../$module_name/", $text{'index_title'}); @@ -23,7 +23,7 @@ if (!($httpd = &find_httpd())) { if (!(-d $config{'httpd_dir'})) { &ui_print_header(undef, $text{'index_title'}, "", undef, 1, 1); print &text('index_eroot', "$config{'httpd_dir'}", - "$gconfig{'webprefix'}/config.cgi?$module_name"),"

\n"; + "@{[&get_webprefix()]}/config.cgi?$module_name"),"

\n"; &ui_print_footer("/", $text{'index'}); exit; } @@ -70,7 +70,7 @@ if (!$htconf) { &ui_print_header(undef, $text{'index_title'}, "", undef, 1, 1); print "

\n"; print &text('index_econf', "$htconfchecked", - "$gconfig{'webprefix'}/config.cgi?$module_name"),"

\n"; + "@{[&get_webprefix()]}/config.cgi?$module_name"),"

\n"; &ui_print_footer("/", $text{'index'}); exit; } diff --git a/apache/reconfig_form.cgi b/apache/reconfig_form.cgi index f8279d530..f8ce2fb49 100755 --- a/apache/reconfig_form.cgi +++ b/apache/reconfig_form.cgi @@ -17,7 +17,7 @@ else { ($ver, $mods) = &httpd_info($httpd = &find_httpd()); if (!$ver) { print &text('reconfig_ever', "$httpd", - "$gconfig{'webprefix'}/config.cgi?$module_name"),"

\n"; + "@{[&get_webprefix()]}/config.cgi?$module_name"),"

\n"; &ui_print_footer("/", $text{'index'}); exit; } diff --git a/bind8/bind8-lib.pl b/bind8/bind8-lib.pl index 3adba5a53..3c4aaeea1 100755 --- a/bind8/bind8-lib.pl +++ b/bind8/bind8-lib.pl @@ -4210,8 +4210,8 @@ return undef if (!$en || $en !~ /yes/i); my $tkeys = &find("trusted-keys", $conf); return undef if (!$tkeys || !@{$tkeys->{'members'}}); return &text('trusted_warning', - $gconfig{'webprefix'}.'/bind8/conf_trusted.cgi')."

\n". - &ui_form_start($gconfig{'webprefix'}.'/bind8/fix_trusted.cgi')."\n". + &get_webprefix().'/bind8/conf_trusted.cgi')."

\n". + &ui_form_start(&get_webprefix().'/bind8/fix_trusted.cgi')."\n". &ui_form_end([ [ undef, $text{'trusted_fix'} ] ]); } diff --git a/bind8/index.cgi b/bind8/index.cgi index 3ac10cfdf..7aa43d434 100755 --- a/bind8/index.cgi +++ b/bind8/index.cgi @@ -19,7 +19,7 @@ if (!-x $config{'named_path'}) { &ui_print_header(undef, $text{'index_title'}, "", undef, 1, 1, 0, &help_search_link("bind", "doc", "google")); print "

",&text('index_enamed', "$config{'named_path'}", - "$gconfig{'webprefix'}/config.cgi?$module_name"),"

\n"; + "@{[&get_webprefix()]}/config.cgi?$module_name"),"

\n"; &foreign_require("software", "software-lib.pl"); my $lnk = &software::missing_install_link("bind", $text{'index_bind'}, diff --git a/burner/edit_profile.cgi b/burner/edit_profile.cgi index c2d65e8ec..82013043d 100755 --- a/burner/edit_profile.cgi +++ b/burner/edit_profile.cgi @@ -18,19 +18,19 @@ else { if ($profile->{'type'} == 2 && !&has_command($config{'mkisofs'})) { print "

",&text('edit_emkisofs', "$config{'mkisofs'}", - "$gconfig{'webprefix'}/config.cgi?$module_name"),"

\n"; + "@{[&get_webprefix()]}/config.cgi?$module_name"),"

\n"; &ui_print_footer("", $text{"index_return"}); exit; } if ($profile->{'type'} == 3 && !&has_command($config{'mpg123'})) { print "

",&text('edit_empg123', "$config{'mpg123'}", - "$gconfig{'webprefix'}/config.cgi?$module_name"),"

\n"; + "@{[&get_webprefix()]}/config.cgi?$module_name"),"

\n"; &ui_print_footer("", $text{"index_return"}); exit; } if ($profile->{'type'} == 4 && !&has_command($config{'cdrdao'})) { print "

",&text('edit_ecdrdao', "$config{'cdrdao'}", - "$gconfig{'webprefix'}/config.cgi?$module_name"),"

\n"; + "@{[&get_webprefix()]}/config.cgi?$module_name"),"

\n"; &ui_print_footer("", $text{"index_return"}); exit; } diff --git a/burner/index.cgi b/burner/index.cgi index 52e69136b..5653f0f22 100755 --- a/burner/index.cgi +++ b/burner/index.cgi @@ -8,7 +8,7 @@ require './burner-lib.pl'; if (!&has_command($config{'cdrecord'})) { print "

",&text('index_ecdrecord', "$config{'cdrecord'}", - "$gconfig{'webprefix'}/config.cgi?$module_name"),"

\n"; + "@{[&get_webprefix()]}/config.cgi?$module_name"),"

\n"; &ui_print_footer("/", $text{"index"}); exit; } diff --git a/caldera/index_top.cgi b/caldera/index_top.cgi index b1de1c5ac..632988ff4 100755 --- a/caldera/index_top.cgi +++ b/caldera/index_top.cgi @@ -103,7 +103,7 @@ foreach $m (@modules) { local $img = -r "$theme_root_directory/$m->{'dir'}/images/icon.gif" ? "/$m->{'dir'}/images/icon.gif" : "/template.gif"; - print "{'dir'}/$lnk'>{'dir'}/$lnk' CLASS=bodyNav>$m->{'desc'}\n"; + print "$m->{'desc'}\n"; if ($pos++ % 3 == 2) { print "\n"; } } diff --git a/cfengine/edit_cfd.cgi b/cfengine/edit_cfd.cgi index 54bb82709..180815d49 100755 --- a/cfengine/edit_cfd.cgi +++ b/cfengine/edit_cfd.cgi @@ -7,7 +7,7 @@ require './cfengine-lib.pl'; if (!&has_command($config{'cfd'})) { print &text('cfd_ecmd', "$config{'cfd'}", - "$gconfig{'webprefix'}/config.cgi?$module_name"),"

\n"; + "@{[&get_webprefix()]}/config.cgi?$module_name"),"

\n"; &ui_print_footer("/", $text{'index'}); exit; } diff --git a/cfengine/edit_push.cgi b/cfengine/edit_push.cgi index 4c30afd87..07b9921c0 100755 --- a/cfengine/edit_push.cgi +++ b/cfengine/edit_push.cgi @@ -7,7 +7,7 @@ require './cfengine-lib.pl'; if (!&has_command($config{'cfrun'})) { print &text('push_ecmd', "$config{'cfrun'}", - "$gconfig{'webprefix'}/config.cgi?$module_name"),"

\n"; + "@{[&get_webprefix()]}/config.cgi?$module_name"),"

\n"; &ui_print_footer("/", $text{'index'}); exit; } diff --git a/cfengine/index.cgi b/cfengine/index.cgi index ee3942f26..76af9ea9a 100755 --- a/cfengine/index.cgi +++ b/cfengine/index.cgi @@ -8,7 +8,7 @@ require './cfengine-lib.pl'; if (!&has_command($config{'cfengine'})) { &ui_print_header(undef, $text{'index_title'}, "", undef, 1, 1); print &text('index_ecommand', "$config{'cfengine'}", - "$gconfig{'webprefix'}/config.cgi?$module_name"),"

\n"; + "@{[&get_webprefix()]}/config.cgi?$module_name"),"

\n"; &ui_print_footer("/", $text{'index'}); exit; } @@ -38,7 +38,7 @@ if ($ver !~ /^1\./) { # Check if config file exists if (!-r $cfengine_conf || -d $config{'cfengine_conf'}) { print &text('index_econfig', "$cfengine_conf", - "$gconfig{'webprefix'}/config.cgi?$module_name"),"

\n"; + "@{[&get_webprefix()]}/config.cgi?$module_name"),"

\n"; &ui_print_footer("/", $text{'index'}); exit; } diff --git a/cfengine/list_hosts.cgi b/cfengine/list_hosts.cgi index 2b146df30..ead8e3df9 100755 --- a/cfengine/list_hosts.cgi +++ b/cfengine/list_hosts.cgi @@ -16,7 +16,7 @@ foreach $h (@hosts) { next if (!$s); push(@titles, &server_name($s)); push(@links, "edit_host.cgi?id=$h->{'id'}"); - push(@icons, "$gconfig{'webprefix'}/servers/images/$s->{'type'}.gif"); + push(@icons, "@{[&get_webprefix()]}/servers/images/$s->{'type'}.gif"); $gothost{$h->{'id'}}++; } if (@links) { diff --git a/chooser.cgi b/chooser.cgi index a0ffdcd09..7c90c78f4 100755 --- a/chooser.cgi +++ b/chooser.cgi @@ -123,10 +123,10 @@ if ($in{'frame'} == 0) { } print "\n"; print "\n"; print "\n"; print "\n"; } @@ -199,7 +199,7 @@ EOF $link = ""; } local @cols; - push(@cols, "$link"); + push(@cols, "$link"); push(@cols, "$link".&html_escape($f).""); push(@cols, &nice_size($st[7])); @tm = localtime($st[9]); @@ -212,7 +212,7 @@ EOF closedir(DIR); print &ui_columns_end(); if ( $cnt >= 10 ) { - print ""; + print ""; print ""; } &popup_footer(); diff --git a/cluster-software/index.cgi b/cluster-software/index.cgi index 17717b287..e0cf823a6 100755 --- a/cluster-software/index.cgi +++ b/cluster-software/index.cgi @@ -30,7 +30,7 @@ foreach $h (@hosts) { "$s->{'host'}:$s->{'port'}")."
". &text('index_count', $count)); push(@links, "edit_host.cgi?id=$h->{'id'}"); - push(@icons, "$gconfig{'webprefix'}/servers/images/$s->{'type'}.gif"); + push(@icons, "@{[&get_webprefix()]}/servers/images/$s->{'type'}.gif"); push(@installed, $count); $gothost{$h->{'id'}}++; } diff --git a/cluster-useradmin/edit_group.cgi b/cluster-useradmin/edit_group.cgi index add4cdec7..49796cfce 100755 --- a/cluster-useradmin/edit_group.cgi +++ b/cluster-useradmin/edit_group.cgi @@ -93,8 +93,8 @@ foreach $h (@hosts) { local ($og) = grep { $_->{'group'} eq $in{'group'} } @{$h->{'groups'}}; if ($og) { local ($s) = grep { $_->{'id'} == $h->{'id'} } @servers; - push(@icons, $gconfig{'webprefix'} ? - ($gconfig{'webprefix'}."/servers/images/".$s->{'type'}.".gif") : + push(@icons, &get_webprefix() ? + (&get_webprefix()."/servers/images/".$s->{'type'}.".gif") : ("../servers/images/".$s->{'type'}.".gif")); push(@links, "edit_host.cgi?id=$h->{'id'}"); push(@titles, $s->{'desc'} ? $s->{'desc'} : $s->{'host'}); diff --git a/cluster-useradmin/edit_user.cgi b/cluster-useradmin/edit_user.cgi index 5d2a2d51b..c0fdfe869 100755 --- a/cluster-useradmin/edit_user.cgi +++ b/cluster-useradmin/edit_user.cgi @@ -408,8 +408,8 @@ foreach $h (@hosts) { local ($ou) = grep { $_->{'user'} eq $in{'user'} } @{$h->{'users'}}; if ($ou) { local ($s) = grep { $_->{'id'} == $h->{'id'} } @servers; - push(@icons, $gconfig{'webprefix'} ? - ($gconfig{'webprefix'}."/servers/images/".$s->{'type'}.".gif") : + push(@icons, &get_webprefix() ? + (&get_webprefix()."/servers/images/".$s->{'type'}.".gif") : ("../servers/images/".$s->{'type'}.".gif")); push(@links, "edit_host.cgi?id=$h->{'id'}"); push(@titles, $s->{'desc'} ? $s->{'desc'} : $s->{'host'}); diff --git a/cluster-useradmin/index.cgi b/cluster-useradmin/index.cgi index 76aee8d22..9798d0c57 100755 --- a/cluster-useradmin/index.cgi +++ b/cluster-useradmin/index.cgi @@ -27,7 +27,7 @@ foreach $h (@hosts) { push(@titles, $s->{'desc'} ? $s->{'desc'} : "$s->{'host'}:$s->{'port'}"); push(@links, $link); - push(@icons, $gconfig{'webprefix'}."/servers/images/". + push(@icons, &get_webprefix()."/servers/images/". $s->{'type'}.".gif"); push(@installed, @{$h->{'packages'}}); $gothost{$h->{'id'}}++; diff --git a/cluster-usermin/index.cgi b/cluster-usermin/index.cgi index 5390a7eaf..0859ff7a7 100755 --- a/cluster-usermin/index.cgi +++ b/cluster-usermin/index.cgi @@ -25,7 +25,7 @@ foreach $h (@hosts) { push(@titles, &server_name($s)."
". &text('index_version', $h->{'version'})); push(@links, "edit_host.cgi?id=$h->{'id'}"); - push(@icons, "$gconfig{'webprefix'}/servers/images/$s->{'type'}.gif"); + push(@icons, "@{[&get_webprefix()]}/servers/images/$s->{'type'}.gif"); $gothost{$h->{'id'}}++; } if (@links) { diff --git a/cluster-webmin/index.cgi b/cluster-webmin/index.cgi index 762758914..c4ad74a17 100755 --- a/cluster-webmin/index.cgi +++ b/cluster-webmin/index.cgi @@ -27,7 +27,7 @@ foreach $h (@hosts) { push(@titles, &server_name($s)."
". &text('index_version', $h->{'version'})); push(@links, "edit_host.cgi?id=$h->{'id'}"); - push(@icons, "$gconfig{'webprefix'}/servers/images/$s->{'type'}.gif"); + push(@icons, "@{[&get_webprefix()]}/servers/images/$s->{'type'}.gif"); $gothost{$h->{'id'}}++; } if (@links) { diff --git a/dhcpd/index.cgi b/dhcpd/index.cgi index c3b9d06e8..d498d7eee 100755 --- a/dhcpd/index.cgi +++ b/dhcpd/index.cgi @@ -35,7 +35,7 @@ if (!-x $config{'dhcpd_path'}) { &ui_print_header(undef, $text{'index_title'}, "", undef, 1, 1, 0, &help_search_link("dhcpd", "man", "doc", "howto", "google")); print &text('index_dhcpdnotfound', $config{'dhcpd_path'}, - "$gconfig{'webprefix'}/config.cgi?$module_name"),"

\n"; + "@{[&get_webprefix()]}/config.cgi?$module_name"),"

\n"; &foreign_require("software", "software-lib.pl"); $lnk = &software::missing_install_link("dhcpd", $text{'index_dhcpd'}, diff --git a/dnsadmin/index.cgi b/dnsadmin/index.cgi index 2ffa658b1..43ad5ba09 100755 --- a/dnsadmin/index.cgi +++ b/dnsadmin/index.cgi @@ -10,7 +10,7 @@ print &ui_hr(); if (!-x $config{'named_pathname'}) { print "

The BIND 4 DNS server $config{'named_pathname'}\n"; print "could not be found on your system. Maybe it is not installed,\n"; - print "or your BIND 4 module\n"; + print "or your BIND 4 module\n"; print "configuration is incorrect.

\n"; print &ui_hr(); &footer("/", "index"); diff --git a/exports-nfs4/exports-lib.pl b/exports-nfs4/exports-lib.pl index 0a50028b8..707086bca 100755 --- a/exports-nfs4/exports-lib.pl +++ b/exports-nfs4/exports-lib.pl @@ -225,7 +225,7 @@ return ($_[0]->{'active'} ? "" : "#").$_[0]->{'dir'}."\t".join(" ", @htxt); sub file_chooser_button2 { my $disabled = ($_[3] == 1) ? "disabled" : ""; - return "\n"; + return "\n"; } #------------------------------------------------------ diff --git a/fetchmail/index.cgi b/fetchmail/index.cgi index b687ba7dd..4884010a4 100755 --- a/fetchmail/index.cgi +++ b/fetchmail/index.cgi @@ -10,7 +10,7 @@ if (!&has_command($config{'fetchmail_path'})) { &help_search_link("fetchmail", "doc", "man", "google")); print "

",&text('index_efetchmail', "$config{'fetchmail_path'}", - "$gconfig{'webprefix'}/config.cgi?$module_name"),"

\n"; + "@{[&get_webprefix()]}/config.cgi?$module_name"),"

\n"; &ui_print_footer("/", $text{'index'}); exit; } diff --git a/file/edit_html.cgi b/file/edit_html.cgi index a8d71ec39..81946159f 100755 --- a/file/edit_html.cgi +++ b/file/edit_html.cgi @@ -23,7 +23,7 @@ if ($in{'file'} ne '' && !&can_access($in{'file'})) { # Output HTMLarea init code print < - _editor_url = "$gconfig{'webprefix'}/$module_name/xinha/"; + _editor_url = "@{[&get_webprefix()]}/$module_name/xinha/"; _editor_lang = "en"; diff --git a/file/index.cgi b/file/index.cgi index ee5a9e619..2e497a9b5 100755 --- a/file/index.cgi +++ b/file/index.cgi @@ -25,9 +25,9 @@ else { $w = 100; $h = 100; if (!$tconfig{'inframe'}) { - $return = ""; + $return = ""; $returnhtml = &text('index_index', - "$gconfig{'webprefix'}/")."

"; + "@{[&get_webprefix()]}/")."

"; } } @@ -57,7 +57,7 @@ if ($main::session_id) { $session = ""; } if (!$access{'noconfig'}) { - $config = ""; + $config = ""; } $iconsize = int($config{'iconsize'}); $root = join(" ", @allowed_roots); diff --git a/filemin/unauthenticated/templates/dialogs.html b/filemin/unauthenticated/templates/dialogs.html index 152cf6066..98cd75a3b 100644 --- a/filemin/unauthenticated/templates/dialogs.html +++ b/filemin/unauthenticated/templates/dialogs.html @@ -329,7 +329,7 @@

$text{'upload_files'}