<% on error resume next if request("acao")="foto" then set oFile = server.CreateObject("Scripting.FileSystemObject") if ofile.FileExists(path & request("foto")) then oFile.DeleteFile(path & request("foto")) end if objconexao.execute("DELETE FROM banners WHERE id="&int(seguranca(request("foto_id")))) response.Clear() response.Redirect "enviar_banner.asp?msg=Banner deletado com sucesso!!&id="&seguranca(request("id")) end if If Err.Number <> 0 Then Response.Write("Houve um erro.
") Response.Write("Descrição do erro: " & Err.Description) Response.Write("
Número do erro: " & Err.Number) Response.End() end if %>

Upload de Banners
Redirecionar *
 
Para deletar um banner clique sobre ele

<% SQL = "SELECT * FROM banners Where categoria="&catAtual set rsCat = ObjConexao.Execute(SQL) if not rsCat.Eof then %> <% cont = 0 do while not rsCat.Eof %> <% cont = cont + 1 rsCat.movenext loop rsCat.close Set rsCat = Nothing %>
&foto=<%=rsCat("foto")%>">" width="468" height="60" border="0" onmouseover="return overlib('Clique no banner para exclui-lo!!');" onMouseOut="return nd();" />
 <%=rsCat("redirecionar")%> 
<%end if%>