当前位置: 首页>>代码示例>>PHP>>正文


PHP check_data函数代码示例

本文整理汇总了PHP中check_data函数的典型用法代码示例。如果您正苦于以下问题:PHP check_data函数的具体用法?PHP check_data怎么用?PHP check_data使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了check_data函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: handle_submit

function handle_submit()
{
    global $selected_id, $Mode;
    $ok = true;
    if ($selected_id != -1) {
        // make from_date start of month and to_date a year minus one day later
        $_POST['from_date'] = start_month($_POST['from_date']);
        $_POST['to_date'] = end_month(add_months($_POST['from_date'], 11));
        if ($_POST['closed'] == 1) {
            if (check_years_before($_POST['from_date'], false)) {
                display_error(_("Cannot CLOSE this year because there are open fiscal years before"));
                set_focus('closed');
                return false;
            }
            $ok = close_year($selected_id);
        } else {
            open_year($selected_id);
        }
        if ($ok) {
            update_fiscalyear($selected_id, $_POST['from_date'], $_POST['to_date'], $_POST['closed']);
            display_notification(_('Selected fiscal year has been updated'));
        }
    } else {
        if (!check_data()) {
            return false;
        }
        add_fiscalyear($_POST['from_date'], $_POST['to_date'], $_POST['closed']);
        display_notification(_('New fiscal year has been added'));
    }
    $Mode = 'RESET';
}
开发者ID:PaulShipley,项目名称:FrontAccounting,代码行数:31,代码来源:fiscalyears.php

示例2: stampa

function stampa($cf, $scoid)
{
    $query = "SELECT *\n\t\t\tFROM jos_comprofiler_2011\n\t\t\tWHERE cb_codicefiscale='" . $cf . "'\n\t\t\tLIMIT 1\n\t\t\t";
    $db_query = mysql_query($query) or die(mysql_error());
    $riga = mysql_fetch_array($db_query);
    //$riga=$riga[0];
    $firstname = $riga['firstname'];
    $lastname = $riga['lastname'];
    $nome = $lastname . " " . $firstname;
    $professione = $riga['cb_professionedisciplina'];
    $datanascita = substr($riga['cb_datadinascita'], 8, 2) . "-" . substr($riga['cb_datadinascita'], 5, 2) . "-" . substr($riga['cb_datadinascita'], 0, 4);
    $luogonascita = $riga['cb_luogodinascita'];
    $pdf =& new Cezpdf('a4');
    $pdf->ezImage("header.jpg", -3, 500, 20, 'left');
    $pdf->selectFont('./fonts/Helvetica.afm');
    $pdf->ezSetCmMargins(2, 2, 2, 2);
    //stampo il titolo
    $text = "\n <b>Programma nazionale per la formazione continua degli operatori della Sanita'</b> \n \n";
    $pdf->ezText($text, 12, array('justification' => 'center', 'spacing' => '1.5'));
    //stampo l'introduzione
    $text = "Premesso che la <b>Commissione Nazionale per la Formazione Continua</b> ha accreditato provvisoriamente il Provider <b>GGALLERY SRL</b>  accreditamento n. <b>39</b> valido fino al 22/04/2012 Premesso che il Provider ha organizzato l'evento formativo n. <b>39-1012</b>, edizione n. 0 denominato \n <b>LA COMUNICAZIONE EFFICACE IN FARMACIA PER UN  CORRETTO APPROCCIO RELAZIONALE CON IL PAZIENTE</b> e tenutosi  dal <b>15/01/2011</b> al <b>31/12/2011</b>, avente come obiettivi didattico/formativo generali: <i>ASPETTI RELAZIONALI (COMUNICAZIONE INTERNA,  ESTERNA, CON PAZIENTE) E UMANIZZAZIONE CURE</i>, assegnando all'evento stesso  N.<b> 10</b> (dieci) Crediti Formativi E.C.M.";
    $pdf->ezText($text, 11, array('justification' => 'centre', 'spacing' => '1.5'));
    $text = "\n \n \n\tIl sottoscritto <b>PAOLO MACRI'</b> \n \n\tRappresentate Legale dell'organizzatore \n\n\tVerificato l'apprendimento del partecipante \n\n\t<b> ATTESTA CHE </b> \n\n\til Dott./la Dott.ssa \n\n\t<b> {$nome} </b> \n\n\tin qualita' di {$professione} \n \n\tnato a {$luogonascita} \n\n\til {$datanascita} \n\n\tha conseguito \n \n\tN. 10 (dieci) Crediti formativi per l'anno 2011\n\t\n  ";
    $pdf->ezText($text, 11, array('justification' => 'centre', 'spacing' => '1'));
    //stampo la data
    $data = check_data($scoid, $idutente);
    $text = " Genova, li {$data} \n \n";
    $pdf->ezText($text, 11, array('justification' => 'left', 'spacing' => '1.5'));
    //stampo la firma
    $text = "IL RAPPRESENTANTE LEGALE DELL'ORGANIZZATORE \n Dott. Paolo Macri' \n \n ";
    $pdf->ezText($text, 11, array('justification' => 'centre', 'spacing' => '1'));
    $pdf->ezImage("firma.jpg", -5, 90, 20, 'center');
    //  echo "non stampo";
    $pdf->ezStream();
}
开发者ID:GGallery,项目名称:MDWEBTV-new,代码行数:35,代码来源:attestato_comunicazione.php

示例3: step

function step($is_submit)
{
    if ($is_submit) {
        return check_data();
    }
    $result = array('html' => render('step_site', array()));
    return $result;
}
开发者ID:Val-Git,项目名称:icms2,代码行数:8,代码来源:site.php

示例4: handle_submit

function handle_submit()
{
    if (!check_data()) {
        return;
    }
    $trans = add_exchange_variation_all($_POST['date'], $_POST['ref'], $_POST['memo_']);
    meta_forward($_SERVER['PHP_SELF'], "AddedID=" . $trans[0] . "&JE=" . $trans[1]);
    //clear_data();
}
开发者ID:knjy24,项目名称:FrontAccounting,代码行数:9,代码来源:revaluate_currencies.php

示例5: update_bank_account

function update_bank_account($id, $bank_name, $account_number, $account_type, $routing_number, $first_name, $last_name, $address_line1, $city, $state, $zip, $country, $default)
{
    global $_TABLES;
    $error = check_data($bank_name, $account_number, $account_type, $routing_number, $first_name, $last_name, $address_line1, $city, $state, $zip, $country);
    if ($error == "") {
        if (isset($_POST['default'])) {
            clear_default_bank();
        }
        DB_query("UPDATE {$_TABLES['ecom_user_bank']} SET ecom_bank_name = '" . $bank_name . "', ecom_bank_accountnumber = '" . $account_number . "', ecom_bank_accounttype = '" . $account_type . "', ecom_bank_routingnumber = '" . $routing_number . "', ecom_bank_first_name = '" . $first_name . "', ecom_bank_last_name = '" . $last_name . "', ecom_bank_address_line1 = '" . $address_line1 . "', ecom_bank_city = '" . $city . "', ecom_bank_state = '" . $state . "', ecom_bank_zip = '" . $zip . "', ecom_bank_country = '" . $country . "', ecom_bank_default = '" . $default . "' WHERE ecom_bankid = " . $id . "");
    }
    return $error;
}
开发者ID:glFusion,项目名称:ecommerce,代码行数:12,代码来源:user_bank_account_functions.php

示例6: handle_submit

function handle_submit()
{
    global $selected_id;
    if (!check_data()) {
        return false;
    }
    if ($selected_id != "") {
        update_exchange_rate($_POST['curr_abrev'], $_POST['date_'], input_num('BuyRate'), input_num('BuyRate'));
    } else {
        add_exchange_rate($_POST['curr_abrev'], $_POST['date_'], input_num('BuyRate'), input_num('BuyRate'));
    }
    return true;
}
开发者ID:ravenii,项目名称:guardocs,代码行数:13,代码来源:exchange_rates.php

示例7: update_credit_card

function update_credit_card($id, $first_name, $middle_name, $last_name, $company, $address_line1, $address_line2, $city, $state, $zip, $country, $card_number, $card_exp_month, $card_exp_year, $card_type, $issue_number, $start_month, $start_year, $default)
{
    global $_TABLES;
    $error = check_data($first_name, $middle_name, $last_name, $company, $address_line1, $address_line2, $city, $state, $zip, $country, $card_number, $card_exp_month, $card_exp_year, $card_type, $issue_number, $start_month, $start_year, $default);
    if ($error == "") {
        //Clear all default credit cards if new default card.
        if ($default != "") {
            clear_default();
        }
        DB_query("UPDATE {$_TABLES['ecom_user_creditcard']} SET ecom_card_firstname = '" . $first_name . "', ecom_card_middlename = '" . $middle_name . "', ecom_card_lastname = '" . $last_name . "', ecom_card_company = '" . $company . "', ecom_card_street1 = '" . $address_line1 . "', ecom_card_street2 = '" . $address_line2 . "', ecom_card_city = '" . $city . "', ecom_card_state = '" . $state . "', ecom_card_postalcode = '" . $zip . "', ecom_card_country = '" . $country . "', ecom_card_accountnumber = '" . $card_number . "', ecom_card_experationmonth = '" . $card_exp_month . "', ecom_card_experationyear = '" . $card_exp_year . "', ecom_card_cardtype = '" . $card_type . "', ecom_card_issuenumber = '" . $issue_number . "', ecom_card_startmonth = '" . $start_month . "', ecom_card_startyear = '" . $start_year . "', ecom_card_default = '" . ($default != "" ? true : false) . "' WHERE ecom_cardid = " . $id . "");
    }
    return $error;
}
开发者ID:glFusion,项目名称:ecommerce,代码行数:13,代码来源:user_credit_card_functions.php

示例8: handle_submit

function handle_submit()
{
    global $selected_id;
    if (!check_data()) {
        return false;
    }
    if (isset($selected_id)) {
        update_fiscalyear($_POST['from_date'], $_POST['closed']);
    } else {
        add_fiscalyear($_POST['from_date'], $_POST['to_date'], $_POST['closed']);
    }
    return true;
}
开发者ID:ravenii,项目名称:guardocs,代码行数:13,代码来源:fiscalyears.php

示例9: handle_submit

function handle_submit()
{
    global $selected_id;
    if (!check_data()) {
        return false;
    }
    if ($selected_id != "") {
        update_currency($_POST['Abbreviation'], $_POST['Symbol'], $_POST['CurrencyName'], $_POST['country'], $_POST['hundreds_name']);
    } else {
        add_currency($_POST['Abbreviation'], $_POST['Symbol'], $_POST['CurrencyName'], $_POST['country'], $_POST['hundreds_name']);
    }
    return true;
}
开发者ID:ravenii,项目名称:guardocs,代码行数:13,代码来源:currencies.php

示例10: check_data

function check_data($arr,$v) {
 foreach($arr as $key=>$value)
 {
	if(!is_array($key))
	{ check($key,$v);}
	else
	{ check_data($key,$v);}
	
	if(!is_array($value))
	{ check($value,$v);}
	else
	{ check_data($value,$v);}
 }
}
开发者ID:noikiy,项目名称:mdwp,代码行数:14,代码来源:waf.php

示例11: handle_submit

function handle_submit()
{
    global $selected_id, $Mode;
    if (!check_data()) {
        return false;
    }
    if ($selected_id != "") {
        update_currency($_POST['Abbreviation'], $_POST['Symbol'], $_POST['CurrencyName'], $_POST['country'], $_POST['hundreds_name'], check_value('auto_update'));
        display_notification(_('Selected currency settings has been updated'));
    } else {
        add_currency($_POST['Abbreviation'], $_POST['Symbol'], $_POST['CurrencyName'], $_POST['country'], $_POST['hundreds_name'], check_value('auto_update'));
        display_notification(_('New currency has been added'));
    }
    $Mode = 'RESET';
}
开发者ID:pthdnq,项目名称:ivalley-svn,代码行数:15,代码来源:currencies.php

示例12: check_data

function check_data($arr, $v)
{
    $url = $_SERVER["PHP_SELF"];
    //排除后台管理
    if (!is_int(strpos($url, 'stourtravel'))) {
        foreach ($arr as $key => $value) {
            if (!is_array($key)) {
                check($key, $v);
            } else {
                check_data($key, $v);
            }
            if (!is_array($value)) {
                check($value, $v);
            } else {
                check_data($value, $v);
            }
        }
    }
}
开发者ID:lz1988,项目名称:stourwebcms,代码行数:19,代码来源:safe.func.php

示例13: defined

<?php

//fdix
defined("ZHANGXUAN") or die("no hacker.");
session_start();
$logincheck = 0;
$loginerrorid = -1;
if (!check_data('letters_code') || md5(strtolower($_POST['letters_code'])) != $_SESSION['letters_code']) {
    $loginerrorid = 2;
} else {
    if (check_data("username") && check_data("password")) {
        $user = db_iconv('username', 'post', true, true);
        $password = db_iconv('password');
        $result = check_post_password($password, $user);
        if (!$result) {
            $logincheck = 0;
            $loginerrorid = 1;
        } else {
            $sql = "SELECT * FROM `users` WHERE `user_name`='{$user}'";
            $rowtemp = queryRow($sql);
            $user_id = $rowtemp['user_id'];
            $user_right = $rowtemp['user_right'];
            $user_thistimelogin_ip = $rowtemp['user_thistimelogin_ip'];
            $user_thislogin_time = $rowtemp['user_thislogin_time'];
            if ($user_right == 1) {
                if (time() - strtotime($user_thislogin_time) < 1800) {
                    $logincheck = 2;
                } else {
                    $sql = "DELETE FROM `cookiedata` WHERE `user_name`='{$user}'";
                    delete($sql);
                    $logincheck = 1;
开发者ID:wooberlong,项目名称:myauth.us,代码行数:31,代码来源:login_check.php

示例14: die

     die(json_encode($ret));
 }
 foreach ($attendees_data as $key => $attendee_data) {
     //处理firstname & lastname
     $attendee_data['name']['en']['firstname'] = trim($attendee_data['name']['en']['firstname']);
     $attendee_data['name']['en']['lastname'] = trim($attendee_data['name']['en']['lastname']);
     //检查firstname & lastname
     if ($attendee_data['name']['en']['firstname'] == '' || $attendee_data['name']['en']['lastname'] == '') {
         $ret['r'] = 'error';
         $ret['msg'] = '10001:' . $texts['required_field_empty'];
         die(json_encode($ret));
     } else {
         $attendees_data[$key]['name']['en'] = json_encode($attendees_data[$key]['name']['en']);
     }
     //检查attendee数据
     $check_ret = check_data($attendees_data[$key], $attendee_config);
     if ($check_ret['r'] == 'error') {
         die(json_encode($check_ret));
     } else {
         $attendees_data[$key] = $check_ret['msg'];
     }
     ##检查email
     // foreach ($attendees_data as $k => $v) {
     //     if ( ($attendee_data['email'] == $v['email'])
     //     && ($key != $k) ) {
     //         $ret['r'] = 'error';
     //         $ret['msg'] = '40002:'.$texts['email_repeat_error_1'];
     //         die(json_encode($ret));
     //     }
     // }
     // $check_ret = Attendee::check_email_exists($activity_id, $attendee_data['email']);
开发者ID:WSKINGS,项目名称:chat_tickets,代码行数:31,代码来源:manage_query.php

示例15: defined

<?php

defined("ZHANGXUAN") or die("no hacker.");
$resetmod = -1;
//1开始输入,2确认中
if (check_data('userid', 'get') && check_data('token', 'get')) {
    $resetmod = 1;
} else {
    if (check_data('user_id') && check_data('user_token') && check_data('oldPassword') && check_data('newPassword') && check_data('newPasswordVerify')) {
        $resetmod = 2;
    } else {
        $resetmod = 0;
    }
}
开发者ID:wooberlong,项目名称:myauth.us,代码行数:14,代码来源:resetpsdmodcheck.php


注:本文中的check_data函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。