function db_getfile($arq, $text, $funcao = "0") { db_postmemory($GLOBALS["_FILES"][$arq]); $DB_FILES = $GLOBALS["DB_FILES"]; $tmp_name = $GLOBALS["tmp_name"]; $name = $GLOBALS["name"]; $size = $GLOBALS["size"]; if ($funcao != "0") { if ($name != "") { system("rm -f {$DB_FILES}/{$funcao}"); copy($tmp_name, "{$DB_FILES}/{$text}"); return $text; } else { if ($text != "") { if ($text != $funcao) { system("mv {$DB_FILES}/{$funcao} {$DB_FILES}/{$text}"); return $text; } else { return $text; } } else { if ($text == "") { system("rm -f {$DB_FILES}/{$funcao}"); return ""; } } } } else { if ($name != "" && $size == 0) { db_erro("O arquivo {$name} não foi encontrado ou ele está vazio. Verifique o seu caminho e o seu tamanho e tente novamente."); } else { copy($tmp_name, "{$DB_FILES}/{$text}"); return $text; } } }
$int_guia_nr = $j - 1; } } next($vt); } $j = 0; reset($vt); for ($i = 0; $i < $tam; $i++) { if (db_indexOf(key($vt), "CHECK") > 0) { $numpres[$j++] = $vt[key($vt)]; } next($vt); } if (isset($valores)) { if (sizeof($valores) != sizeof($numpres)) { db_erro("<br> Matriz inválida!", 1); } $tam = sizeof($valores); $sqlerro = false; db_inicio_transacao(); //for($i = 0;$i < $tam;$i++) { // Lançamento sem movimento - parte I if (!empty($str_movimento) and $str_movimento != 'Sem Movimento') { // ######################### TEM QUE INCLUIR NA cancdebitos, cancdebitosproc ######################### include "classes/db_cancdebitos_classe.php"; include "classes/db_cancdebitosproc_classe.php"; include "classes/db_cancdebitosreg_classe.php"; include "classes/db_cancdebitosprocreg_classe.php"; include "classes/db_issvarsemmov_classe.php"; include "classes/db_issvarsemmovreg_classe.php"; $clcancdebitos = new cl_cancdebitos();