Esempio n. 1
0
 $email = $idna_convert->encode(validate($_POST['email'], 'email'));
 $customernumber = validate($_POST['customernumber'], 'customer number', '/^[A-Za-z0-9 \\-]*$/Di');
 $def_language = validate($_POST['def_language'], 'default language');
 $password = validate($_POST['new_customer_password'], 'new password');
 $gender = intval_ressource($_POST['gender']);
 $move_to_admin = isset($_POST['move_to_admin']) ? intval_ressource($_POST['move_to_admin']) : 0;
 $custom_notes = validate(str_replace("\r\n", "\n", $_POST['custom_notes']), 'custom_notes', '/^[^\\0]*$/');
 $custom_notes_show = $result['custom_notes_show'];
 if (isset($_POST['custom_notes_show'])) {
     $custom_notes_show = intval_ressource($_POST['custom_notes_show']);
 }
 $diskspace = intval_ressource($_POST['diskspace']);
 if (isset($_POST['diskspace_ul'])) {
     $diskspace = -1;
 }
 $traffic = doubleval_ressource($_POST['traffic']);
 if (isset($_POST['traffic_ul'])) {
     $traffic = -1;
 }
 $subdomains = intval_ressource($_POST['subdomains']);
 if (isset($_POST['subdomains_ul'])) {
     $subdomains = -1;
 }
 $emails = intval_ressource($_POST['emails']);
 if (isset($_POST['emails_ul'])) {
     $emails = -1;
 }
 $email_accounts = intval_ressource($_POST['email_accounts']);
 if (isset($_POST['email_accounts_ul'])) {
     $email_accounts = -1;
 }
Esempio n. 2
0
     $interval_payment = $result['interval_payment'];
     $customer_categories_once_array = explode('-', $result['customer_categories_once']);
     $customer_categories_once = $result['customer_categories_once'];
     $customer_categories_period_array = explode('-', $result['customer_categories_period']);
     $customer_categories_period = $result['customer_categories_period'];
 }
 if ($enable_billing_data_edit === true && $settings['billing']['activate_billing'] == '1') {
     $interval_fee = doubleval(str_replace(',', '.', $_POST['interval_fee']));
     $interval_length = intval($_POST['interval_length']);
     $interval_type = in_array($_POST['interval_type'], getIntervalTypes('array')) ? $_POST['interval_type'] : 'm';
     $setup_fee = doubleval(str_replace(',', '.', $_POST['setup_fee']));
     $payment_every = intval($_POST['payment_every']);
     $additional_traffic_fee = doubleval(str_replace(',', '.', $_POST['additional_traffic_fee']));
     $additional_traffic_unit = doubleval_ressource($_POST['additional_traffic_unit']) * 1024 * 1024;
     $additional_diskspace_fee = doubleval(str_replace(',', '.', $_POST['additional_diskspace_fee']));
     $additional_diskspace_unit = doubleval_ressource($_POST['additional_diskspace_unit']) * 1024;
     if (isset($_POST['taxclass']) && intval($_POST['taxclass']) != 0 && isset($taxclasses[$_POST['taxclass']])) {
         $taxclass = $_POST['taxclass'];
     } else {
         $taxclass = '0';
     }
     if ($result['service_active'] == 0 && $service_active == 0) {
         $servicestart_date = $result['servicestart_date'];
     } else {
         $servicestart_date = validate($_POST['servicestart_date'], html_entity_decode($lng['service']['start_date']), '/^(19|20)\\d\\d[-](0[1-9]|1[012])[-](0[1-9]|[12][0-9]|3[01])$/', '', array('0000-00-00', '0', ''));
     }
     $serviceend_date = $result['serviceend_date'];
 } else {
     $interval_fee = $result['interval_fee'];
     $interval_length = $result['interval_length'];
     $interval_type = $result['interval_type'];