Esempio n. 1
0
//add quote to testimonial
if (isset($_POST['action']) && $_POST['action'] == 'add_quote_to_testimonial') {
    $the_main = new main\main();
    $agenda = new agenda\agenda_main();
    $output = $the_main->add_speaker_to_testimonial($_POST['block_id'], $_POST['quote_id'], $_POST['type'], 2);
    $result = $agenda->get_testimonial_data($output['agenda_day'], $output['agenda_category_id'], $output['block']);
    if (isset($result)) {
        echo $result;
    }
}
//delete quote from testimonial
if (isset($_POST['action']) && $_POST['action'] == 'delete_quote_from_testimonial') {
    $the_main = new main\main();
    $agenda = new agenda\agenda_main();
    $output = $the_main->delete_speaker_from_testimonial($_POST['block_id'], $_POST['quote_id'], $_POST['type'], 2);
    $result = $agenda->get_testimonial_data($output['agenda_day'], $output['agenda_category_id'], $output['block']);
    if (isset($result)) {
        echo $result;
    }
}
//add new quote
if (isset($_POST['action']) && $_POST['action'] == 'add_new_quote') {
    $the_main = new main\main();
    $result = $the_main->add_new_quote($_POST['author']);
    if (isset($result)) {
        $_SESSION['Result'] = 'Success';
        echo 'Data Saved!';
    }
}
//Get abstract
if (isset($_POST['action']) && $_POST['action'] == 'get_quote_data_for_edit') {