103 |
- |
1 |
<?php
|
|
|
2 |
|
|
|
3 |
/***************************************************************************
|
|
|
4 |
* Copyright (C) 2009-2011 by Geo Varghese(www.seopanel.in) *
|
|
|
5 |
* sendtogeo@gmail.com *
|
|
|
6 |
* *
|
|
|
7 |
* This program is free software; you can redistribute it and/or modify *
|
|
|
8 |
* it under the terms of the GNU General Public License as published by *
|
|
|
9 |
* the Free Software Foundation; either version 2 of the License, or *
|
|
|
10 |
* (at your option) any later version. *
|
|
|
11 |
* *
|
|
|
12 |
* This program is distributed in the hope that it will be useful, *
|
|
|
13 |
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
|
|
14 |
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
|
|
15 |
* GNU General Public License for more details. *
|
|
|
16 |
* *
|
|
|
17 |
* You should have received a copy of the GNU General Public License *
|
|
|
18 |
* along with this program; if not, write to the *
|
|
|
19 |
* Free Software Foundation, Inc., *
|
|
|
20 |
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
|
|
|
21 |
***************************************************************************/
|
|
|
22 |
|
|
|
23 |
include_once("includes/sp-load.php");
|
|
|
24 |
checkLoggedIn();
|
|
|
25 |
|
|
|
26 |
// check for access to seo tool
|
|
|
27 |
isUserHaveAccessToSeoTool("saturation-checker");
|
|
|
28 |
|
|
|
29 |
include_once(SP_CTRLPATH."/saturationchecker.ctrl.php");
|
|
|
30 |
$controller = New SaturationCheckerController();
|
|
|
31 |
$controller->view->menu = 'seotools';
|
|
|
32 |
$controller->layout = 'ajax';
|
|
|
33 |
$controller->set('spTextTools', $controller->getLanguageTexts('seotools', $_SESSION['lang_code']));
|
|
|
34 |
$controller->spTextSat = $controller->getLanguageTexts('saturation', $_SESSION['lang_code']);
|
|
|
35 |
$controller->set('spTextSat', $controller->spTextSat);
|
|
|
36 |
|
|
|
37 |
if($_SERVER['REQUEST_METHOD'] == 'POST'){
|
|
|
38 |
|
|
|
39 |
switch($_POST['sec']){
|
|
|
40 |
|
|
|
41 |
case "generate":
|
|
|
42 |
if(SP_USER_GEN_REPORT || isAdmin()){
|
|
|
43 |
$controller->generateReports($_POST);
|
|
|
44 |
} else {
|
|
|
45 |
showErrorMsg($_SESSION['text']['label']["Access denied"]);
|
|
|
46 |
}
|
|
|
47 |
break;
|
|
|
48 |
|
|
|
49 |
case "reports":
|
|
|
50 |
$controller->showReports($_POST);
|
|
|
51 |
break;
|
|
|
52 |
|
|
|
53 |
case "saturation":
|
|
|
54 |
$controller->printSearchEngineSaturation($_POST);
|
|
|
55 |
break;
|
|
|
56 |
|
|
|
57 |
case "graphical-reports":
|
|
|
58 |
$controller->showGraphicalReports($_POST);
|
|
|
59 |
break;
|
|
|
60 |
|
|
|
61 |
default:
|
|
|
62 |
if (isQuickCheckerEnabled()) {
|
|
|
63 |
$controller->findSearchEngineSaturation($_POST);
|
|
|
64 |
} else {
|
|
|
65 |
showErrorMsg($_SESSION['text']['label']["Access denied"]);
|
|
|
66 |
}
|
|
|
67 |
break;
|
|
|
68 |
}
|
|
|
69 |
|
|
|
70 |
}else{
|
|
|
71 |
switch($_GET['sec']){
|
|
|
72 |
|
|
|
73 |
case "saturation":
|
|
|
74 |
$controller->printSearchEngineSaturation($_GET);
|
|
|
75 |
break;
|
|
|
76 |
|
|
|
77 |
case "generate":
|
|
|
78 |
$controller->showGenerateReports($_GET);
|
|
|
79 |
break;
|
|
|
80 |
|
|
|
81 |
case "reports":
|
|
|
82 |
$controller->showReports($_GET);
|
|
|
83 |
break;
|
|
|
84 |
|
|
|
85 |
case "graphical-reports":
|
|
|
86 |
$controller->showGraphicalReports($_GET);
|
|
|
87 |
break;
|
|
|
88 |
|
|
|
89 |
default:
|
|
|
90 |
$controller->showSaturationChecker();
|
|
|
91 |
break;
|
|
|
92 |
}
|
|
|
93 |
}
|
|
|
94 |
|
|
|
95 |
?>
|