1. The forums will be archived and moved to a read only mode in about 2 weeks (mid march).

Scan folder

Discussion in 'Development' started by Felic, Nov 4, 2021.

  1. Felic

    Felic Spider

    Messages:
    7
    Hello,

    How can I scan a folder that has folders inside? So a folder is scanned, and if there are folders inside, the name of the folder is taken. How does that work I've already done scandir but that still makes the files in the folder, but only need the folder.

    Thx for your help.
     
  2. Primus

    Primus Zombie Pigman

    Messages:
    749
    It made no sense.

    Are you trying to recursively iterate over a directory?
     
    minijaham likes this.
  3. Kyd

    Kyd Zombie Pigman

    Messages:
    678
    GitHub:
    boi1216
    Filter out directories from scandir using is_dir
     
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.