Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums Back End Select ALL subfolders

  • This topic is empty.
Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #34357
    stevendeeds
    Member

    hey guys, I’m trying to run an if statement that targets all subfolders.

    Not sure what i’m looking for: I’ve tried an asterisk and the /.. thing. What should I be doing to target all subfolders?

    $folder = dirname($_SERVER["PHP_SELF"]);
    if ($folder != '/images' || $folder = '/folder/*' )//trying to target all subfolders
    {};
    #87223
    chrisburton
    Participant

    @stevendeeds and do what with them?

    #87232
    clokey2k
    Participant

    I think the OP is trying to evaluate if he is in a specific set of folders.
    I’ll word the query out to see if that is what the OP wants.

    “IF ( (NOT in the ‘images’ folder) OR (it is within the ‘folder’ folder))
    { “you are either not in the Images folder, or your in my hidden ‘folder’ then Go away!”}

    Like a PHP replacement for a .htaccess rule?

    This would assume you only want a decision made base on the folder that you are in, and not that you wish to ‘do something’ with the folder itself?

    Although I cannot help with the actual problem, I hope I have made it easier to ‘identify’ the problem :-s

Viewing 3 posts - 1 through 3 (of 3 total)
  • The forum ‘Back End’ is closed to new topics and replies.