prefix.'Appointments';
$userid=$_REQUEST['userid'];
$username = $wpdb->get_var("SELECT user_login FROM {$wpdb->users} WHERE ID = '{$userid}'");
get_currentuserinfo();
$user=$current_user->user_login;
$admin_email = get_option('admin_email');
$lastId = $wpdb->get_var("SELECT max(appointment_id) FROM $table"); // Get last inserted id
$res=$wpdb->get_results("SELECT * from $table WHERE appointment_id='".$lastId."'");
foreach($res as $val){
$a=$val->email_id;
}
$path = $this->options['upload_image'];
$img = "";
/*
Change your message body in the given $subjectPara variables.
$subjectPara1 means 'first paragraph in message body', $subjectPara2 means'first paragraph in message body',
if you don't want more than 1 para, just put NULL in unused $subjectPara variables.
*/
$subtitle="Hi Admin";
$subjectPara1 = 'You are successfully rejected appointment of User '.$username.'!';
$subjectPara2 = 'Thank you';
$message = ''.
'
'.$subtitle.'
'. ''.$subjectPara1.'
'. ''.$subjectPara2.'
'. '