Ejemplo n.º 1
0
function add_item()
{
    $fields = array();
    foreach ($_REQUEST as $key => $value) {
        if (strpos($key, "new_") === 0 && $key != "new_id" && $key != "new_en") {
            $fields[substr($key, 4)] = $value;
        }
    }
    $customer = new customer_class((int) $fields["customer_id"]);
    $customer->daryaft((int) $fields["mablagh"], (int) $_SESSION[conf::app . "_user_id"], $fields["tozihat"], hamed_pdateBack($fields["tarikh"]));
}
Ejemplo n.º 2
0
function add_item($gname, $table, $fields, $col)
{
    $typ = $GLOBALS["typ"];
    $conf = new conf();
    $mysql = new mysql_class();
    foreach ($fields as $key => $value) {
        if (strpos($key, "new_") === 0 && $key != "new_id" && $key != "new_en") {
            $fields[substr($key, 4)] = $value;
        }
    }
    $customer = new customer_class((int) $fields["customer_id"]);
    $customer->daryaft((int) umonize($fields["mablagh"]), (int) $_SESSION[$conf->app . "_user_id"], $fields["tozihat"], $typ, hamed_pdateBack($fields["tarikh"]));
    return $ret;
}