Skip to content

Commit ab7597c

Browse files
author
mcramer
committed
Implemented FS#2379 - Add perl option to web sites (apache2 mod_perl2)
Fixed (partly) FS#2310 - Template switch not working in mailuser module, for dashlets and the login page
1 parent d3a2851 commit ab7597c

File tree

8 files changed

+35
-0
lines changed

8 files changed

+35
-0
lines changed
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
-- --------------------------------------------------------
2+
3+
ALTER TABLE `web_domain` ADD `perl` enum('n','y') NOT NULL default 'n' AFTER `python`;
4+
5+

install/sql/ispconfig3.sql

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1643,6 +1643,7 @@ CREATE TABLE `web_domain` (
16431643
`php` varchar(32) NOT NULL default 'y',
16441644
`ruby` enum('n','y') NOT NULL default 'n',
16451645
`python` enum('n','y') NOT NULL default 'n',
1646+
`perl` enum('n','y') NOT NULL default 'n',
16461647
`redirect_type` varchar(255) default NULL,
16471648
`redirect_path` varchar(255) default NULL,
16481649
`seo_redirect` varchar(255) default NULL,

interface/web/index.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,8 @@
3131
require_once('../lib/config.inc.php');
3232
require_once('../lib/app.inc.php');
3333

34+
if(!isset($_SESSION['s']['module']['name'])) $_SESSION['s']['module']['name'] = 'login';
35+
3436
$app->uses('tpl');
3537
$app->tpl->newTemplate('main.tpl.htm');
3638

interface/web/sites/form/web_domain.tform.php

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -230,6 +230,12 @@
230230
),*/
231231
'value' => ''
232232
),
233+
'perl' => array (
234+
'datatype' => 'VARCHAR',
235+
'formtype' => 'CHECKBOX',
236+
'default' => 'n',
237+
'value' => array(0 => 'n',1 => 'y')
238+
),
233239
'ruby' => array (
234240
'datatype' => 'VARCHAR',
235241
'formtype' => 'CHECKBOX',

interface/web/sites/lib/lang/de_web_domain.lng

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,7 @@ $wb['php_fpm_use_socket_txt'] = 'Benutze Socket für PHP-FPM';
8080
$wb['ipv6_address_txt'] = 'IPv6-Adresse';
8181
$wb['error_no_sni_txt'] = 'SNI for SSL is not activated on this server. You can enable only one SSL certificate on each IP address.';
8282
$wb['python_txt'] = 'Python';
83+
$wb['perl_txt'] = 'Perl';
8384
$wb['pm_max_children_txt'] = 'PHP-FPM pm.max_children';
8485
$wb['pm_start_servers_txt'] = 'PHP-FPM pm.start_servers';
8586
$wb['pm_min_spare_servers_txt'] = 'PHP-FPM pm.min_spare_servers';

interface/web/sites/lib/lang/en_web_domain.lng

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -81,6 +81,7 @@ $wb["www_to_non_www_txt"] = 'www -> non-www';
8181
$wb["php_fpm_use_socket_txt"] = 'Use Socket For PHP-FPM';
8282
$wb["error_no_sni_txt"] = 'SNI for SSL is not activated on this server. You can enable only one SSL certificate on each IP address.';
8383
$wb["python_txt"] = 'Python';
84+
$wb["perl_txt"] = 'Perl';
8485
$wb["pm_max_children_txt"] = 'PHP-FPM pm.max_children';
8586
$wb["pm_start_servers_txt"] = 'PHP-FPM pm.start_servers';
8687
$wb["pm_min_spare_servers_txt"] = 'PHP-FPM pm.min_spare_servers';

interface/web/sites/templates/web_domain_edit.htm

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -79,6 +79,12 @@ <h2><tmpl_var name="list_head_txt"></h2>
7979
{tmpl_var name='ssi'}
8080
</div>
8181
</div>
82+
<div class="ctrlHolder apache">
83+
<p class="label">{tmpl_var name='perl_txt'}</p>
84+
<div class="multiField">
85+
{tmpl_var name='perl'}
86+
</div>
87+
</div>
8288
<div class="ctrlHolder apache">
8389
<p class="label">{tmpl_var name='ruby_txt'}</p>
8490
<div class="multiField">

server/conf/vhost.conf.master

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -109,6 +109,19 @@
109109
</IfModule>
110110
</tmpl_if>
111111

112+
<tmpl_if name='perl' op='==' value='y'>
113+
<IfModule mod_perl.c>
114+
PerlModule ModPerl::Registry
115+
PerlModule Apache2::Reload
116+
<Directory {tmpl_var name='web_document_root_www'}>
117+
SetHandler perl-script
118+
PerlResponseHandler ModPerl::Registry
119+
PerlOptions +ParseHeaders
120+
Options +ExecCGI
121+
</Directory>
122+
</IfModule>
123+
</tmpl_if>
124+
112125
<tmpl_if name='python' op='==' value='y'>
113126
<IfModule mod_python.c>
114127
<Directory {tmpl_var name='web_document_root_www'}>

0 commit comments

Comments
 (0)