Support » Plugins » Hacks » wp_mkdir_p not working

  • Hi,
    I’ve written the plugin Edge Suite which handles animations in form of OAM files, which are nothing else then ZIPs. I’m using the codex method wp_mkdir_p to create nested directory structures. Turns out some people have problems with it as it just fails. Any clue why that might be? It’s really strange, this really common functionality is only being called 4 times in wp core, almost looks like devs know it doesn’t work….

    Am happy about any hints, as I can’t reproduce the errors on my servers and it’s therefore really hard to debug it.

Viewing 2 replies - 1 through 2 (of 2 total)
  • Moderator bcworkz


    The word “attempt” appears frequently on that page 🙂

    I suspect various permission schemes implemented by admins or hosts will sometimes stymie this function. About all you can do is fail gracefully when false is returned.

    I forgot to mention, that mk_dir and chmod work when using them on none nested folders somewhere in the code as I’m creating basic plugin folders that way.

    As far as I can tell the essential part of the recursion is based on mk_dir and chmod, which work for themselfs, therefore I don’t get where and why it fails.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘wp_mkdir_p not working’ is closed to new replies.