Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
ISPConfig
ISPConfig 3
Commits
318ace2f
Commit
318ace2f
authored
Apr 14, 2008
by
tbrehm
Browse files
No commit message
No commit message
parent
e2c5f8b5
Changes
1
Hide whitespace changes
Inline
Side-by-side
server/plugins-available/apache2_plugin.inc.php
View file @
318ace2f
...
@@ -238,7 +238,7 @@ class apache2_plugin {
...
@@ -238,7 +238,7 @@ class apache2_plugin {
if
(
is_array
(
$tmp_symlinks_array
))
{
if
(
is_array
(
$tmp_symlinks_array
))
{
foreach
(
$tmp_symlinks_array
as
$tmp_symlink
)
{
foreach
(
$tmp_symlinks_array
as
$tmp_symlink
)
{
$tmp_symlink
=
str_replace
(
"[client_id]"
,
$client_id
,
$tmp_symlink
);
$tmp_symlink
=
str_replace
(
"[client_id]"
,
$client_id
,
$tmp_symlink
);
$tmp_symlink
=
str_replace
(
"[website_domain]"
,
$data
[
"
new
"
][
"domain"
],
$tmp_symlink
);
$tmp_symlink
=
str_replace
(
"[website_domain]"
,
$data
[
"
old
"
][
"domain"
],
$tmp_symlink
);
// Remove trailing slash
// Remove trailing slash
if
(
substr
(
$tmp_symlink
,
-
1
,
1
)
==
'/'
)
$tmp_symlink
=
substr
(
$tmp_symlink
,
0
,
-
1
);
if
(
substr
(
$tmp_symlink
,
-
1
,
1
)
==
'/'
)
$tmp_symlink
=
substr
(
$tmp_symlink
,
0
,
-
1
);
// create the symlinks, if not exist
// create the symlinks, if not exist
...
@@ -389,6 +389,13 @@ class apache2_plugin {
...
@@ -389,6 +389,13 @@ class apache2_plugin {
$app
->
log
(
"Removing symlink:
$vhost_symlink
=>
$vhost_file
"
,
LOGLEVEL_DEBUG
);
$app
->
log
(
"Removing symlink:
$vhost_symlink
=>
$vhost_file
"
,
LOGLEVEL_DEBUG
);
}
}
// remove old symlink, if domain name of the site has changed
if
(
$this
->
action
==
'update'
&&
$data
[
"old"
][
"domain"
]
!=
''
&&
$data
[
"new"
][
"domain"
]
!=
$data
[
"old"
][
"domain"
])
{
$vhost_symlink
=
escapeshellcmd
(
$web_config
[
"vhost_conf_enabled_dir"
]
.
'/'
.
$data
[
"old"
][
"domain"
]
.
'.vhost'
);
unlink
(
$vhost_symlink
);
$app
->
log
(
"Removing symlink:
$vhost_symlink
=>
$vhost_file
"
,
LOGLEVEL_DEBUG
);
}
// request a httpd reload when all records have been processed
// request a httpd reload when all records have been processed
$app
->
services
->
restartServiceDelayed
(
'httpd'
,
'reload'
);
$app
->
services
->
restartServiceDelayed
(
'httpd'
,
'reload'
);
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment