9) Bem, estou com uma duvida sobre download de um arquivo.txt pelo browser internet explorer 5.0, tento iniciar automaticamente o donwload logo ao abrir numa pagina php ou html, funciona com um arquivo.zip, sem problema, mas o problema é quando tento fazer um download do arquivo.txt, ai o browser abre o arquivo.txt, e não faz o download, queria abrir diretamente a janela de “Download de arquivo:”, em vez de abrir o arquivo.txt no browser, tem como fazer isso:
fiz estes testes, funciona o download somente para arquivos zipados:
em php...
<?
header("Location: arquivo.zip");
?>
em html
<META HTTP-EQUIV= "refresh" CONTENT="2; URL=http://teste/arquivo.zip">
estes dois exemplos funcionam, mas somente se for zipado o arquivo..
Já tentei utilizar os comandos abaixo, mas continua abrindo o arquivo txt no browser:
<?php
header ('Content-type: octed-stream');
include ("arquivo.txt");
?>
<?php
header ('Content-type:application/octed-stream');
include ("arquivo.txt");
?>
<?php
Header("Content-Disposition: attachment;
filename=arquivo.txt");
?>
Ruivaldo Neto <rneto@GameBox.net>