Commit 517a6b6b06fa1961a15d348278984c82608d59d1
1 parent
4bb38c4e
Exists in
CEP
and in
7 other branches
Alteraco dos arquivos solicitacao.class.php e funcoes.php para a correcao da extensao de arquivos
Showing
2 changed files
with
12 additions
and
0 deletions
Show diff stats
class/solicitacao.class.php
... | ... | @@ -878,6 +878,11 @@ class Solicitacao { |
878 | 878 | } |
879 | 879 | } |
880 | 880 | } |
881 | + | |
882 | + $ext = getExtensaoArquivo($arquivo['name']); | |
883 | + | |
884 | + $fullArquivo = "lda_".$idsolicitacao."_mov_".$idmovimentacao.".".$ext; | |
885 | + ?> | |
881 | 886 | |
882 | 887 | //se o status da demanda for "aberto" altera para "em tramitação" |
883 | 888 | if($status == "A") | ... | ... |
inc/funcoes.php
... | ... | @@ -187,6 +187,13 @@ function validaTipoArquivo($mime, $extensoes) |
187 | 187 | |
188 | 188 | } |
189 | 189 | |
190 | + | |
191 | + | |
192 | +function getExtensaoArquivo($nomearquivo){ | |
193 | + $aux = explode(".",$nomearquivo); | |
194 | + return $aux[sizeof($aux)-1]; | |
195 | + } | |
196 | + | |
190 | 197 | /* |
191 | 198 | * Smarty plugin |
192 | 199 | * ------------------------------------------------------------- | ... | ... |