<?php
/**
- * stats_function.php
*
- * SourceForge: Breaking Down the Barriers to Open Source Development
* Copyright 1999-2001 (c) VA Linux Systems
- * http://sourceforge.net
+ * Copyright 2010, FusionForge Team
+ * Copyright (C) 2010 Alain Peyrat - Alcatel-Lucent
+ * http://fusionforge.org
*
+ * This file is part of FusionForge. FusionForge 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 Licence, or (at your option)
+ * any later version.
+ *
+ * FusionForge 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 FusionForge; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
*/
require_once $gfwww.'include/HTML_Graphs.php';
$rows = db_numrows($result);
if (!$result || $rows < 1) {
- echo '<h1>Stats Problem</h1>';
- echo db_error();
+ echo '<p class="error">Stats Problem'.db_error().'</p>';
} else {
$j=0;
for ($i=0; $i<$rows; $i++) {
GraphIt($name_string,$vals,'Page Views By Week');
}
- echo '<p> </p>';
-
/*
Projects added by week
*/
$rows = db_numrows($result);
if (!$result || $rows < 1) {
- echo '<h1>Stats Problem</h1>';
- echo db_error();
+ echo '<p class="error">Stats Problem'.db_error().'</p>';
} else {
$count=array();
$dates=array();
}
GraphIt($dates,$count,'New Projects Added Each Week');
}
- echo '<p> </p>';
/*
Users added by week
$rows = db_numrows($result);
if (!$result || $rows < 1) {
- echo '<h1>Stats Problem</h1>';
- echo db_error();
+ echo '<p class="error">Stats Problem'.db_error().'</p>';
} else {
$count=array();
$dates=array();
}
GraphIt($dates,$count,'New Users Added Each Week');
}
- echo '<p> </p>';
}
$rows = db_numrows($result);
if (!$result || $rows < 1) {
- echo '<h1>Stats Problem</h1>';
- echo db_error();
+ echo '<p class="error">Stats Problem'.db_error().'</p>';
} else {
GraphResult($result,'Logo Showings By Day');
}
- echo '<p> </p>';
-
/*
logo impressions/group
*/
$rows = db_numrows($result);
if (!$result || $rows < 1) {
- echo '<h1>Stats Problem</h1>';
- echo db_error();
+ echo '<p class="error">Stats Problem'.db_error().'</p>';
} else {
GraphResult($result,'Logo Showings By Project');
}
-
- echo '<p> </p>';
-
}
$rows = db_numrows($result);
if (!$result || $rows < 1) {
- echo '<h1>Stats Problem</h1>';
- echo db_error();
+ echo '<p class="error">Stats Problem'.db_error().'</p>';
} else {
GraphResult($result,'Page Views By Browser');
}
- echo '<p> </p>';
/*
Platform
$rows = db_numrows($result);
if (!$result || $rows < 1) {
- echo '<h1>Stats Problem</h1>';
- echo db_error();
+ echo '<p class="error">Stats Problem'.db_error().'</p>';
} else {
GraphResult($result,'Page Views By Platform');
}
- echo '<p> </p>';
/*
Browser/ver
$rows = db_numrows($result);
if (!$result || $rows < 1) {
- echo '<h1>Stats Problem</h1>';
- echo db_error();
+ echo '<p class="error">Stats Problem'.db_error().'</p>';
} else {
ShowResultSet($result,'Page Views By Platform/Browser Version');
}
- echo '<p> </p>';
}
-
-?>