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
0ea0630e
Commit
0ea0630e
authored
Jul 21, 2009
by
tbrehm
Browse files
Change path in .htaccess file for stats when the client has been changed.
parent
5bebbcba
Changes
1
Show whitespace changes
Inline
Side-by-side
server/plugins-available/apache2_plugin.inc.php
View file @
0ea0630e
...
...
@@ -756,7 +756,7 @@ class apache2_plugin {
}
//* Create .htaccess and .htpasswd file for website statistics
if
(
!
is_file
(
$data
[
"new"
][
"document_root"
]
.
'/web/stats/.htaccess'
))
{
if
(
!
is_file
(
$data
[
"new"
][
"document_root"
]
.
'/web/stats/.htaccess'
)
or
$data
[
"old"
][
"document_root"
]
!=
$data
[
"new"
][
"document_root"
]
)
{
if
(
!
is_dir
(
$data
[
"new"
][
"document_root"
]
.
'/web/stats'
))
mkdir
(
$data
[
"new"
][
"document_root"
]
.
'/web/stats'
);
$ht_file
=
"AuthType Basic
\n
AuthName
\"
Members Only
\"\n
AuthUserFile "
.
$data
[
"new"
][
"document_root"
]
.
"/.htpasswd_stats
\n
<limit GET PUT POST>
\n
require valid-user
\n
</limit>"
;
file_put_contents
(
$data
[
"new"
][
"document_root"
]
.
'/web/stats/.htaccess'
,
$ht_file
);
...
...
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