5 * Copyright 2004 (c) GForge LLC
8 * @author Tim Perdue tim@gforge.org
11 * This file is part of GForge.
13 * GForge is free software; you can redistribute it and/or modify
14 * it under the terms of the GNU General Public License as published by
15 * the Free Software Foundation; either version 2 of the License, or
16 * (at your option) any later version.
18 * GForge is distributed in the hope that it will be useful,
19 * but WITHOUT ANY WARRANTY; without even the implied warranty of
20 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21 * GNU General Public License for more details.
23 * You should have received a copy of the GNU General Public License
24 * along with GForge; if not, write to the Free Software
25 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
28 require_once('../env.inc.php');
29 require_once $gfwww.'include/pre.php';
30 require_once $gfcommon.'reporting/report_utils.php';
31 require_once $gfcommon.'reporting/Report.class.php';
32 require_once $gfcommon.'reporting/ReportSetup.class.php';
34 session_require( array('group'=>$sys_stats_group,'A') );
36 echo report_header(_('Main Page'));
37 if (getStringFromRequest('submit') && getStringFromRequest('im_sure')) {
41 $r = new ReportSetup();
43 if (!$r->initialSetup()) {
44 echo $r->getErrorMessage();
45 form_release_key(getStringFromRequest("form_key"));
47 Header("Location: index.php?feedback=Successfully+Rebuilt");
52 echo _('<h3>Reporting System Initialization</h3><p>Occasionally, if cronjobs failed or the database was damaged, you may have to rebuild the reporting tables.<p>If you are sure you want to rebuild all the reporting tables, check the "I\'m Sure" box and click the button below.<p>This could take a couple minutes, so DO NOT CLICK MORE THAN ONCE.<p>');
55 <form action="<?php echo getStringFromServer('PHP_SELF'); ?>" method="post">
57 <input type="checkbox" name="im_sure" value="1"><?php echo _('I am sure'); ?><p>
59 <input type="submit" name="submit" value="<?php echo _('Press ONLY ONCE'); ?>">
68 // c-file-style: "bsd"