/** * * @param Array $requestdata * Callback function for creating user account. */ function createuseraccount($requestdata) { if (empty($requestdata)) { exit('Invalid Request.'); } if (!isset($requestdata['email'])) { exit('Email id is required.'); } if (!isset($requestdata['password'])) { exit('Password is required.'); } if (validateemail($requestdata['email'])) { $dd = new FinditDynamoDbUser(); $result = $dd->createUserProfile($requestdata); return $result; } }
$errorstring .= "Sorry, your name must be between 4 and 30 characters.<br />\n"; } if (!preg_match('/^([\\w\\.])+$/i', $username)) { $errorstring .= "Sorry, your name must be alphanumeric and contain no spaces.<br />\n"; } if ($password) { $passlength = strlen($password); if ($passlength < 4) { $errorstring .= "Sorry, your password must be at least 4 characters.<br />\n"; } } else { $errorstring .= "You must provide a password!<br />\n"; } if (isset($_POST['email']) && strlen($email)) { /* Check if valid email address */ if (!validateemail($email)) { // Provided in common.php $errorstring .= "You must provide a valid email address!<br />\n"; } if ($db->emailexists($email) == true) { $errorstring .= "That email has already been used to register an account!<br />\n"; } } else { $errorstring .= "You must provide an email address!<br />\n"; } if ($errorstring == "") { // No errors encountered so far, attempt to register if (THprofile_regpolicy == 1) { $initial_status = 0; // pending admin approval } else {
$process[$key][stripslashes($k)] = $v; $process[] =& $process[$key][stripslashes($k)]; } else { $process[$key][stripslashes($k)] = stripslashes($v); } } } unset($process); } //print_r($_POST); $arr = array('translation' => 'Translating per page (MS Word with font size 12)', 'mobphone' => 'Mobile phone with a Ukrainian SIM card rental (Kharkov only)', 'conference' => '3 way conference call', 'airport' => 'Picking up at the airport, bus station or train station and transfer to the place of staying, free luggage carrier service included (Kharkov only)', 'interpreting' => 'Interpreting (personal meetings, touristic excursions)', 'ast' => 'Accompanying/ assisting/ tour-guiding', 'car' => 'Car with driver (Kharkov only)', 'personal' => 'Your personal / business endeavors facilitator services: Running a news-paper and TV ad for your personal or business endeavor and searching for the contacts for your personal or business needs', 'legal' => 'Legal help to foreign citizens in Kharkov', 'assistance' => 'Assistance with finding investment real estate as well as other assets for purchase in Kharkov, including automobiles', 'detective' => 'Private detective service on the territory of Ukraine', 'consulting' => 'Consulting on investment opportunities in Ukraine, prospective fields of investing and advice on how to start up a business in the country for a foreign citizen as well as marketing research as to the field of business that is of interest for you'); if (empty($_POST['textinfo'])) { header("Location: failure.php"); exit; } if (!validateemail($_POST['email'])) { header("Location: failure.php"); exit; } if (count($_POST) > 3) { //tanya.proidenko@gmail.com $to = '*****@*****.**'; $subject = 'From site Iwka'; $message = 'Data from letter: <br />'; $message .= 'Text information: ' . $_POST['textinfo'] . '<br />'; foreach ($arr as $key => $ar) { if (!empty($_POST[$key])) { $message .= $ar . ': ' . $_POST[$key] . ' <br />'; } } $headers = "From: " . $_POST['email'] . "\r\n" . "Reply-To: " . $_POST['email'] . "\r\n" . "X-Mailer: PHP" . phpversion() . "\r\n" . 'MIME-Version: 1.0' . "\r\n" . 'Content-type: text/html; charset=utf-8\\r\\nContent-Transfer-Encoding: 8bit\\r\\nX-Priority: 1\\r\\nX-MSMail-Priority: High\\r\\n';