Skip to content
This repository has been archived by the owner on Nov 25, 2020. It is now read-only.

Commit

Permalink
Use br instead of newline for post-update script
Browse files Browse the repository at this point in the history
  • Loading branch information
cdujeu committed Sep 18, 2014
1 parent cb988eb commit 82dcca5
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions dist/php/5.3.4.php
Expand Up @@ -11,7 +11,7 @@
rename(AJXP_INSTALL_PATH."/conf/bootstrap_repositories.php".".new-".date("Ymd"), AJXP_INSTALL_PATH."/conf/bootstrap_repositories.php");
}

echo "The bootstrap_context and bootstrap_repositories files were replaced by the new version, the .pre-update version is kept.\n";
echo "<br>The bootstrap_context and bootstrap_repositories files were replaced by the new version, the .pre-update version is kept.";

$sqliteUpgrade = 'CREATE TABLE ajxp_changes (
seq INTEGER PRIMARY KEY AUTOINCREMENT,
Expand Down Expand Up @@ -245,13 +245,13 @@

} else {

echo "DB Already upgraded via the script";
echo "<br>DB Already upgraded via the script<br>";

}

} else {

echo "Nothing to do for the DB";
echo "<br>Nothing to do for the DB<br>";

}

Expand Down Expand Up @@ -298,17 +298,17 @@ function updateBaseHtaccessContent(){
}

if(is_writeable(AJXP_INSTALL_PATH."/.htaccess")){
echo 'Updating Htaccess';
echo '<br>Updating Htaccess';
file_put_contents(AJXP_INSTALL_PATH."/.htaccess", $htContent);
}else{
echo 'Cannot write htaccess file, please copy and paste the code below: <pre>'.$htContent.'</pre>';
echo '<br>Cannot write htaccess file, please copy and paste the code below: <br><pre>'.$htContent.'</pre>';
}
}

function upgradeRootRoleForWelcome(){
$rootRole = AuthService::getRole("ROOT_ROLE");
if(!empty($rootRole)){
echo 'Upgrading Root Role to let users access the new welcome page';
echo '<br>Upgrading Root Role to let users access the new welcome page<br>';
$rootRole->setAcl("ajxp_home", "rw");
$rootRole->setParameterValue("core.conf", "DEFAULT_START_REPOSITORY", "ajxp_home");
AuthService::updateRole($rootRole);
Expand All @@ -322,10 +322,10 @@ function upgradeRootRoleForWelcome(){
$content = file_get_contents($publicHtaccess);
if(strpos($content, "RewriteCond") === false){
if(is_writable($publicHtaccess)){
echo '\nUpdating public folder htaccess file\n';
echo '<br>Updating public folder htaccess file<br>';
file_put_contents($publicHtaccess, buildPublicHtaccessContent());
}else{
echo 'You should update your public htaccess file to server the new shares : <pre>'.buildPublicHtaccessContent().'</pre>';
echo '<br>You should update your public htaccess file to server the new shares : <br><pre>'.buildPublicHtaccessContent().'</pre>';
}
}
}
Expand Down

0 comments on commit 82dcca5

Please sign in to comment.