PHP: glob - Manual in Deutsh
PHP: glob - Manual in French
PHP: glob - Manual in Polish

You Are At PHP: glob - Manual Area


recent searches:
include functions , variable functions , post functions...




If you are new to PHP or just need to refresh your skills, this is the place to start. This series of tutorials will give you the basic knowledge you will need to create a simple PHP website.

PHP is a reflective programming language originally designed for producing dynamic web pages.[1] PHP is used mainly in server-side scripting, but can be used from a command line interface or in standalone graphical applications. Textual User Interfaces can also be created using ncurses.

PHP Manual
PrevNext

glob

(PHP 4 >= 4.3.0, PHP 5)

glob -- Find pathnames matching a pattern

Description

array glob ( string pattern [, int flags] )

The glob() function searches for all the pathnames matching pattern according to the rules used by the libc glob() function, which is similar to the rules used by common shells. No tilde expansion or parameter substitution is done.

Returns an array containing the matched files/directories, an empty array if no file matched or FALSE on error.

Valid flags:

Example 1. Convenient way how glob() can replace opendir() and friends.

<?php
foreach (glob("*.txt") as $filename) {
    echo
"$filename size " . filesize($filename) . "\n";
}
?>

The above example will output something similar to:

funclist.txt size 44686
funcsummary.txt size 267625
quickref.txt size 137820

Note: This function will not work on remote files as the file to be examined must be accessible via the servers filesystem.

Note: This function isn't available on some systems (e.g. old Sun OS).

See also opendir(), readdir(), closedir(), and fnmatch().

Wyjatkowej jakości meble medyczne w xmebel
Kotły gazowe
Grzejniki
zespół weselny warszawa
Największa baza pytań egzamin doradca podatkowy testy na doradce podatkowego

Another Useful functions:


zend-macro.zend-set-global-var | zend-macro.zend-set-global-var-with-length | zend-macro.zend-init-module-globals | zend-macro.zend-extern-module-globals | zend-macro.zend-end-module-globals | zend-macro.zend-declare-module-globals | zend-macro.zend-begin-module-globals | zend-api.zend-u-is-auto-global | zend-api.zend-u-delete-global-variable | zend-api.zend-register-auto-global | zend-api.zend-is-auto-global | zend-api.zend-ini-global-shutdown | zend-api.zend-delete-global-variable | zend-api.zend-auto-global-disable-jit | security.globals | migration52.global-constants | function.runkit-superglobals | function.glob | function.cpdf-global-set-document-limits |


PHP is a widely-used general-purpose scripting language that is especially suited for Web development and can be embedded into HTML. If you are new to PHP and want to get some idea of how it works, try the introductory tutorial. After that, check out the online manual, and the example archive sites and some of the other resources available in the links section.