Why is it whenever I use scandir() I receive periods at the beginning of the array?

后端 未结 5 1400
北荒
北荒 2020-12-01 15:45

Why is it whenever I use scandir() I receive periods at the beginning of the array?

Array
(
    [0] => .
    [1] => ..
    [2] => bar.php
    [3] =&         


        
5条回答
  •  挽巷
    挽巷 (楼主)
    2020-12-01 16:14

    In Unix convention . is a link to the current directory while .. is a link to the parent directory. Both of them exist as a file in the directory index.

提交回复
热议问题