コード例 #1
0
ファイル: resume_action.php プロジェクト: pamalite/yel
    $data = array();
    $data['id'] = $_POST['experience'];
    $data['industry'] = $_POST['industry'];
    $data['from'] = $_POST['from'];
    $data['to'] = $to;
    $data['role'] = $_POST['role'];
    $data['place'] = $_POST['place'];
    $data['work_summary'] = sanitize($_POST['work_summary']);
    $data['reason_for_leaving'] = $_POST['reason_for_leaving'];
    if ($_POST['experience'] == "0") {
        if (!$resume->create_work_experience($data)) {
            echo 'ko1';
            exit;
        }
    } else {
        if (!$resume->update_work_experience($data)) {
            echo 'ko2';
            exit;
        }
    }
    echo 'ok';
    exit;
}
if ($_POST['action'] == 'get_educations') {
    $resume = new Resume($_POST['member'], $_POST['id']);
    $educations = $resume->get_educations();
    $response = array('resume' => array('educations' => $educations));
    header('Content-type: text/xml');
    echo $xml_dom->get_xml_from_array($response);
    exit;
}