Warning: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead in /www/htdocs/w01136d3/wordpress/wp-content/plugins/deans_code_highlighter/geshi.php on line 2147

Warning: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead in /www/htdocs/w01136d3/wordpress/wp-content/plugins/deans_code_highlighter/geshi.php on line 2147

Warning: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead in /www/htdocs/w01136d3/wordpress/wp-content/plugins/deans_code_highlighter/geshi.php on line 2147

Warning: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead in /www/htdocs/w01136d3/wordpress/wp-content/plugins/deans_code_highlighter/geshi.php on line 2147

Warning: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead in /www/htdocs/w01136d3/wordpress/wp-content/plugins/deans_code_highlighter/geshi.php on line 2147

Warning: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead in /www/htdocs/w01136d3/wordpress/wp-content/plugins/deans_code_highlighter/geshi.php on line 2147

Warning: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead in /www/htdocs/w01136d3/wordpress/wp-content/plugins/deans_code_highlighter/geshi.php on line 2147

Warning: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead in /www/htdocs/w01136d3/wordpress/wp-content/plugins/deans_code_highlighter/geshi.php on line 2147

Warning: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead in /www/htdocs/w01136d3/wordpress/wp-content/plugins/deans_code_highlighter/geshi.php on line 2147

Warning: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead in /www/htdocs/w01136d3/wordpress/wp-content/plugins/deans_code_highlighter/geshi.php on line 2147

Warning: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead in /www/htdocs/w01136d3/wordpress/wp-content/plugins/deans_code_highlighter/geshi.php on line 2147

Warning: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead in /www/htdocs/w01136d3/wordpress/wp-content/plugins/deans_code_highlighter/geshi.php on line 2147

Warning: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead in /www/htdocs/w01136d3/wordpress/wp-content/plugins/deans_code_highlighter/geshi.php on line 2147

Warning: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead in /www/htdocs/w01136d3/wordpress/wp-content/plugins/deans_code_highlighter/geshi.php on line 2147

Warning: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead in /www/htdocs/w01136d3/wordpress/wp-content/plugins/deans_code_highlighter/geshi.php on line 2147

Warning: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead in /www/htdocs/w01136d3/wordpress/wp-content/plugins/deans_code_highlighter/geshi.php on line 2147

Warning: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead in /www/htdocs/w01136d3/wordpress/wp-content/plugins/deans_code_highlighter/geshi.php on line 2147

Warning: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead in /www/htdocs/w01136d3/wordpress/wp-content/plugins/deans_code_highlighter/geshi.php on line 2147

Warning: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead in /www/htdocs/w01136d3/wordpress/wp-content/plugins/deans_code_highlighter/geshi.php on line 2147

Warning: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead in /www/htdocs/w01136d3/wordpress/wp-content/plugins/deans_code_highlighter/geshi.php on line 2147

Warning: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead in /www/htdocs/w01136d3/wordpress/wp-content/plugins/deans_code_highlighter/geshi.php on line 2147

Warning: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead in /www/htdocs/w01136d3/wordpress/wp-content/plugins/deans_code_highlighter/geshi.php on line 2147

Warning: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead in /www/htdocs/w01136d3/wordpress/wp-content/plugins/deans_code_highlighter/geshi.php on line 2147

Warning: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead in /www/htdocs/w01136d3/wordpress/wp-content/plugins/deans_code_highlighter/geshi.php on line 2147

Der gewöhnliche Weg einen Verzeichnisinhalt mit PHP auszulesen, ist das Verzeichnishandle. Der Nachteil hierbei ist, dass die Einträge nicht alphabetisch sortiert zurückgeliefert werden. Seit PHP5 gibt für diesen Fall aber mit scandir eine sehr einfache Lösung.

Gewöhnliches Auslesen von Verzeichnissen unsortiert

span class=“st0″>".""."".."".""\n"

Komfortables Auslesen mit scandir

scandir liefert ein sortiertes Array mit dem Verzeichnisinhalt. Als Parameter wird der Pfad übergeben, der Punkt in diesem Beispiel steht für das gleiche Verzeichnis, in dem das Script liegt.

span class=“st0″>‘.‘));

Dienstag, 7. Dezember 2010 [PHP] RSS 2.0 / Trackback senden

Noch keine Kommentare.

Einen Kommentar hinterlassen

XHTML allowed tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>