New feature: upgrade process from Scuttle to SemanticScuttle
git-svn-id: https://semanticscuttle.svn.sourceforge.net/svnroot/semanticscuttle/trunk@42 b3834d28-1941-0410-a4f8-b48e95affb8f
This commit is contained in:
parent
e3327d5803
commit
11d5e81c1c
2 changed files with 62 additions and 34 deletions
34
admin.php
34
admin.php
|
@ -1,34 +0,0 @@
|
|||
<?php
|
||||
/***************************************************************************
|
||||
Copyright (C) 2006 - 2007 Scuttle project
|
||||
http://sourceforge.net/projects/scuttle/
|
||||
http://scuttle.org/
|
||||
|
||||
This program is free software; you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation; either version 2 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
***************************************************************************/
|
||||
|
||||
// Uncomment the following lines to execute the admin script. Don't forget to re-comment them after using.
|
||||
|
||||
/*
|
||||
require_once('header.inc.php');
|
||||
$tagstatservice = & ServiceFactory :: getServiceInstance('TagStatService');
|
||||
$templateservice = & ServiceFactory :: getServiceInstance('TemplateService');
|
||||
|
||||
// Update the stats
|
||||
$tagstatservice->updateAllStat();
|
||||
|
||||
echo "Admin script executed: OK!";
|
||||
*/
|
||||
?>
|
62
upgrade.php
Normal file
62
upgrade.php
Normal file
|
@ -0,0 +1,62 @@
|
|||
<?php
|
||||
/***************************************************************************
|
||||
Copyright (C) 2006 - 2007 Scuttle project
|
||||
http://sourceforge.net/projects/scuttle/
|
||||
http://scuttle.org/
|
||||
|
||||
This program is free software; you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation; either version 2 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
***************************************************************************/
|
||||
|
||||
|
||||
/////////////////
|
||||
// WARNING!
|
||||
// Comment the two lines of code below to make work the script.
|
||||
// You have to put // at the beginning of lines to comment them.
|
||||
// BEFORE upgrading, don't forget to make a BACKUP of your database.
|
||||
// AFTER upgrading, don't forget to UN-COMMENT the lines back.
|
||||
/////////////////
|
||||
|
||||
echo "Please edit the 'upgrade.php' file into SemanticScuttle/ to start upgrading";
|
||||
exit();
|
||||
|
||||
/////////////////
|
||||
// This part below will be executed once you comment the two lines above
|
||||
/////////////////
|
||||
require_once('header.inc.php');
|
||||
$tagstatservice = & ServiceFactory :: getServiceInstance('TagStatService');
|
||||
$templateservice = & ServiceFactory :: getServiceInstance('TemplateService');
|
||||
?>
|
||||
|
||||
<h1>Upgrade</h1>
|
||||
<h2>From Scuttle 0.7.2 to SemanticScuttle 0.87</h2>
|
||||
<ul>
|
||||
<li>1/ Make a <b>backup</b> of your database</li>
|
||||
<li>2/ Create the missing tables
|
||||
<ul>
|
||||
<li>Open "tables.sql" (into your SemanticScuttle directory) with a text editor</li>
|
||||
<li>Copy to your database the last three tables : sc_tags2tags, sc_tagsstats, sc_commondescription</li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>3/ Complete the upgrade by clicking on the following link : <a href="upgrade.php?action=upgrade">upgrade</a></li>
|
||||
</ul>
|
||||
<?php
|
||||
if($_GET['action']=="upgrade") {
|
||||
// Update the stats
|
||||
$tagstatservice->updateAllStat();
|
||||
echo "Upgrade script executed: OK!<br/><br/>";
|
||||
echo "For security reason, don't forget to uncomment back the first lines into \"upgrade.php\"<br/><br/>";
|
||||
echo 'In case of problem during upgrade, please use our <a href="http://sourceforge.net/tracker/?group_id=211356&atid=1017431">sourceforge page</a> to inform us. Thank you.';
|
||||
}
|
||||
?>
|
Loading…
Reference in a new issue