prefix . "ap_services"; $servicedetails="SELECT * FROM $table_name WHERE `id` ='$sid'"; $servicedetails = $wpdb->get_row($servicedetails); $servicedetails->category_id; } else { $servicedetails = NULL; } ?>
   " >
   " >
   Enter Numeric Value.
Eg: 5, 10, 15, 30, 60", "appointzilla"); ?>" >
   " >
   Enter Numeric Value
Eg: 5 , 10, 25, 50, 100, 150", "appointzilla"); ?>" >
   " >
   " >
   
prefix . "ap_services"; $insert_service = "INSERT INTO $table_name ( `name` , `desc` , `duration` , `unit` , `cost` , `availability`, `category_id` )VALUES ('$servicename', '$desc', '$Duration', '$durationunit', '$cost', '$availability', '$category');"; if($wpdb->query($insert_service)) { echo ""; } echo ""; } //upadte a service if(isset($_POST['updateservice'])) { $sid=$_GET['sid']; $servicename=$_POST['name']; $desc=$_POST['desc']; $Duration=$_POST['Duration']; $durationunit=$_POST['durationunit']; $cost=$_POST['cost']; $availability=$_POST['availability']; $category=$_POST['category']; $table_name = $wpdb->prefix . "ap_services"; $update_service ="UPDATE $table_name SET `name` = '$servicename', `desc` = '$desc', `duration` = '$Duration', `unit` = '$durationunit', `cost` = '$cost', `availability` = '$availability', `category_id` = '$category' WHERE `id` ='$sid';"; $wpdb->query($update_service); echo ""; echo ""; } ?>