/************************************************************************/ /* ATutor */ /************************************************************************/ /* Copyright (c) 2002-2010 */ /* http://atutor.ca */ /* 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. */ /************************************************************************/ // $Id$ if (!defined('AT_INSTALLER_INCLUDE_PATH') || !defined('AT_INCLUDE_PATH')) { exit; } include AT_INCLUDE_PATH . 'install/install.inc.php'; if (isset($_POST['submit']) && $_POST['action'] == 'process') { install_step_accounts($_POST['admin_username'], $_POST['form_admin_password_hidden'], $_POST['admin_email'], $_POST['site_name'], $_POST['email'], $_POST['account_username'], $_POST['form_account_password_hidden'], $_POST['account_fname'], $_POST['account_lname'], $_POST['account_email'], $_POST['just_social'], $_POST['home_url'], get_atutor_installation_path(AT_INSTALLER_INCLUDE_PATH), $_POST['step2']['db_host'], $_POST['step2']['db_port'], $_POST['step2']['db_login'], $_POST['step2']['db_password'], $_POST['step2']['db_name'], $_POST['step2']['tb_prefix'], true); if (!isset($errors)) { unset($_POST['admin_username']); unset($_POST['form_admin_password_hidden']); unset($_POST['admin_email']); unset($_POST['account_username']); unset($_POST['form_account_password_hidden']); unset($_POST['account_email']); unset($_POST['home_url']); unset($_POST['email']); unset($_POST['site_name']); unset($_POST['just_social']); unset($errors); unset($_POST['submit']); unset($action); store_steps($step);
$result = mysql_query($sql ,$db); } $_POST['just_social'] = intval($_POST['just_social']); if ($_POST['just_social'] > 0){ $sql = "INSERT INTO ".$_POST['step2']['tb_prefix']."config VALUES ('just_social', '1')"; $result = mysql_query($sql ,$db); } //if fresh install, use SET NAME to set the mysql connection to UTF8 $sql = "INSERT INTO ".$_POST['step2']['tb_prefix']."config VALUES ('set_utf8', '1')"; mysql_query($sql ,$db); // Calculate the ATutor installation path and save into database for the usage of // session associated path @ include/vitals.inc.php $sql = "INSERT INTO ".$_POST['step2']['tb_prefix']."config VALUES ('session_path', '".get_atutor_installation_path(AT_INCLUDE_PATH)."')"; mysql_query($sql ,$db); unset($_POST['admin_username']); unset($_POST['form_admin_password_hidden']); unset($_POST['admin_email']); unset($_POST['account_username']); unset($_POST['form_account_password_hidden']); unset($_POST['account_email']); unset($_POST['home_url']); unset($_POST['email']); unset($_POST['site_name']); unset($_POST['just_social']); unset($errors); unset($_POST['submit']);