Add templates for the main .htaccess so the RewriteBase can adapted

if the main /limesurvey alias is disabled
tags/0.1.3_el5 0.1.3_el5
Daniel Berteaud 11 years ago
parent 85cc0e73ef
commit 46f288ba57
  1. 1
      createlinks
  2. 14
      root/etc/e-smith/templates/usr/share/limesurvey/.htaccess/10All

@ -5,6 +5,7 @@ use esmith::Build::CreateLinks qw(:all);
# Templates to expand # Templates to expand
templates2events("/etc/e-smith/sql/init/limesurvey", qw(bootstrap-console-save webapps-update)); templates2events("/etc/e-smith/sql/init/limesurvey", qw(bootstrap-console-save webapps-update));
templates2events("/usr/share/limesurvey/application/config/config.php", qw(bootstrap-console-save webapps-update)); templates2events("/usr/share/limesurvey/application/config/config.php", qw(bootstrap-console-save webapps-update));
templates2events("/usr/share/limesurvey/.htaccess", qw(bootstrap-console-save webapps-update));
safe_symlink("/etc/e-smith/templates-default/template-begin-php", "root/etc/e-smith/templates/usr/share/limesurvey/application/config/config.php/template-begin"); safe_symlink("/etc/e-smith/templates-default/template-begin-php", "root/etc/e-smith/templates/usr/share/limesurvey/application/config/config.php/template-begin");
safe_symlink("/etc/e-smith/templates-default/template-end-php", "root/etc/e-smith/templates/usr/share/limesurvey/application/config/config.php/template-end"); safe_symlink("/etc/e-smith/templates-default/template-end-php", "root/etc/e-smith/templates/usr/share/limesurvey/application/config/config.php/template-end");

@ -0,0 +1,14 @@
<IfModule mod_rewrite.c>
RewriteEngine on
{
my $alias = $limesurvey{'AliasOnPrimary'} || 'enabled';
if ($alias ne 'disabled'){
$OUT .= " RewriteBase /limesurvey\n";
}
else{
$OUT .= '';
}
}
RewriteCond %\{REQUEST_FILENAME\} !-f
RewriteRule . index.php
</IfModule>
Loading…
Cancel
Save