http_send_content_type
(PECL pecl_http >= 0.10.0)
http_send_content_type — Enviar cabecera Content-Type
Descripción
bool http_send_content_type
([ string
$content_type = "application/x-octetstream"
] )Adjuntar la cabecera Content-Type de la entidad enviada.
Nota: Esta función debería ser utilizada en conjunción con http_send_data(), http_send_file() y http_send_stream().
Parámetros
-
content_type -
tipo de contenido deseado (primario/secundario)
Valores devueltos
Devuelve TRUE en caso de éxito o FALSE en caso de error.
Errores/Excepciones
Puede provocar E_WARNING cuando parezca que content_type
no tiene una parte primaria y una secundaria.
Ver también
- http_send_data() - Enviar datos arbitrarios
- http_send_file() - Enviar un fichero
- http_send_stream() - Enviar flujo
- la clase HttpResponse si está utilizando PHP 5.1.0 and above