http_send_content_disposition
(PECL pecl_http >= 0.10.0)
http_send_content_disposition — Send Content-Disposition
Opis
$filename
[, bool $inline = false
] )Send the Content-Disposition. Nagłowek Content-Disposition jest bardzo użyteczny jeśli dane aktualnie wysyłane pochodzą z pliku lub czegoś podobnego, które powinny być "zapisane" przez klienta/użytkownika (np. przez okienko popup przeglądarki "Zapisz jako...").
Informacja: Ta funkcja będzie przypuszczalnie użyta w powiązaniu z http_send_data(), http_send_file() i http_send_stream().
Parametry
-
filename -
the file name the "Save as..." dialog should display
-
inline -
if set to
TRUEand the user agent knows how to handle the content type, it will probably not cause the popup window to be shown
Zwracane wartości
Zwraca TRUE w przypadku powodzenia, FALSE w
przypadku błędu.
Zobacz też:
- http_send_data() - Send arbitrary data
- http_send_file() - Send file
- http_send_stream() - Send stream
- Klasa HttpResponse jeśli używasz PHP 5.1.0 lub późniejszego
