summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Xerl/Setup/Configure.pm13
-rw-r--r--xerl.conf1
2 files changed, 10 insertions, 4 deletions
diff --git a/Xerl/Setup/Configure.pm b/Xerl/Setup/Configure.pm
index f58b51b..e490c82 100644
--- a/Xerl/Setup/Configure.pm
+++ b/Xerl/Setup/Configure.pm
@@ -40,6 +40,8 @@ sub parse {
sub defaults {
my $self = $_[0];
+ $self->set_is_ipv6( $ENV{REMOTE_ADDR} =~ /:/ ? 1 : 0 );
+
$self->set_proto('http') if exists $ENV{HTTPS};
$self->set_site( $self->get_defaultcontent() )
@@ -50,8 +52,13 @@ sub defaults {
$self->set_template( $self->get_defaulttemplate() )
unless $self->template_exists();
- $self->set_style( $self->get_defaultstyle() )
- unless $self->style_exists();
+ unless ($self->style_exists()) {
+ if ($self->get_is_ipv6()) {
+ $self->set_style( $self->get_ipv6style() )
+ } else {
+ $self->set_style( $self->get_defaultstyle() )
+ }
+ }
$self->set_proto( $self->get_defaultproto() )
unless $self->proto_exists();
@@ -129,8 +136,6 @@ sub defaults {
$self->set_contentpath( $self->get_hostpath() . 'content/' );
- $self->set_is_ipv6( $ENV{REMOTE_ADDR} =~ /:/ ? 1 : 0 );
-
return undef;
}
diff --git a/xerl.conf b/xerl.conf
index 58fd7bf..c8561b3 100644
--- a/xerl.conf
+++ b/xerl.conf
@@ -12,6 +12,7 @@ defaulthost=default
defaultoutputformat=html5
defaultproto=http
defaultstyle=css3.css
+ipv6style=css3-ipv6.css
defaulttemplate=html5
hidesubhome=1
hostroot=/var/www/xerlhosts/