Exemple #1
0
 *   along with this program; if not, write to the                         *
 *   Free Software Foundation, Inc.,                                       *
 *   59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.             *
 ***************************************************************************/
include_once "includes/sp-load.php";
checkLoggedIn();
include_once SP_CTRLPATH . "/website.ctrl.php";
include_once SP_CTRLPATH . "/keyword.ctrl.php";
$controller = new WebsiteController();
$controller->view->menu = 'seotools';
$controller->layout = 'ajax';
$controller->set('sectionHead', 'Websites');
if ($_SERVER['REQUEST_METHOD'] == 'POST') {
    switch ($_POST['sec']) {
        case "create":
            $controller->createWebsite($_POST);
            break;
        case "update":
            $controller->updateWebsite($_POST);
            break;
    }
} else {
    switch ($_GET['sec']) {
        case "Activate":
            $controller->__changeStatus($_GET['websiteId'], 1);
            $controller->listWebsites($_GET);
            break;
        case "Inactivate":
            $controller->__changeStatus($_GET['websiteId'], 0);
            $controller->listWebsites($_GET);
            break;