Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Aviance School is one of the largest web solutions platform in India for developers to learn and share their programming knowledge and build their careers.
Here is the syntax you can try it.
$user_id = $this->session->userdata('user_id');
RewriteEngine On
RewriteCond %{HTTP_HOST} ^78\.46\.80\.117
RewriteRule (.*) http://aviancetechnologies.com/$1 [R=301,L]
RewriteRule ^([A-Za-z0-9-]+)/([0-9]+)/?$ $1.php?id=$1 [NC,L] # Handle ID requests
RewriteRule ^([^\.]+)$ $1.php [NC,L]
RewriteCond %{HTTP_HOST} ^www\.aviancetechnologies\.com$
RewriteRule ^/?$ "http\:\/\/aviancetechnologies\.com\/" [R=301,L]
RewriteCond %{HTTP_USER_AGENT} libwww-perl.*
RewriteRule .* ? [F,L]
Please try using the below code
<?php
require 'class.smtp.php';
require 'class.phpmailer.php';
function smtpmailSend($to, $from, $from_name, $subject, $body) {
global $error;
$mail = new PHPMailer(); // create a new object
$mail->IsSMTP(); // enable SMTP
$mail->SMTPDebug = 0; // debugging: 1 = errors and messages, 2 = messages only
$mail->SMTPAuth = true; // authentication enabled
$mail->SMTPSecure = 'ssl'; // secure transfer enabled REQUIRED for GMail
$mail->SMTPAutoTLS = false;
$mail->Host = 'smtp.gmail.com';
$mail->Port = 465;
$mail->Username = 'technologiesaviance@gmail.com';
$mail->Password = 'xxxxxxxxx'; // Your Gmail Password
$mail->SetFrom($from, $from_name);
$mail->Subject = $subject;
$mail->Body = $body;
$mail->AddAddress($to);
if(!$mail->Send()) {
$error = 'Mail error: '.$mail->ErrorInfo;
return false;
} else {
$error = 'Message sent!';
return true;
}
}
if (smtpmailSend('bikash.hutait03@gmail.com', 'technologiesaviance@gmail.com', 'aviance', 'test mail', 'Hi! This is Bikash..')) {
//echo "Send!";
}
if (!empty($error)) echo $error;
?>
You will get ‘class.smtp.php’ & ‘class.phpmailer.php’ file from here