PHP Doku:: Retrieve options for a stream/wrapper/context - function.stream-context-get-options.html

Verlauf / Chronik / History: (1) anzeigen

Sie sind hier:
Doku-StartseitePHP-HandbuchFunktionsreferenzSonstige GrunderweiterungenStreamsStream Funktionenstream_context_get_options

Ein Service von Reinhard Neidl - Webprogrammierung.

Stream Funktionen

<<stream_context_get_default

stream_context_get_params>>

stream_context_get_options

(PHP 4 >= 4.3.0, PHP 5)

stream_context_get_optionsRetrieve options for a stream/wrapper/context

Beschreibung

array stream_context_get_options ( resource $stream_or_context )

Returns an array of options on the specified stream or context.

Parameter-Liste

stream_or_context

The stream or context to get options from

Rückgabewerte

Returns an associative array with the options.

Beispiele

Beispiel #1 stream_context_get_options() example

<?php
$params 
= array("method" => "POST");

stream_context_get_default(array("http" => $params));

var_dump(stream_context_get_options(stream_context_get_default()));

?>

Das oben gezeigte Beispiel erzeugt eine ähnliche Ausgabe wie:

array(1) {
  ["http"]=>
  array(1) {
    ["method"]=>
    string(4) "POST"
  }
}


Keine BenutzerBeiträge.
- Beiträge aktualisieren...



PHP Powered Diese Seite bei php.net
The PHP manual text and comments are covered by the Creative Commons Attribution 3.0 License © the PHP Documentation Group - Impressum - mail("TO:Reinhard Neidl",...)