opendir('Y/m/d') ???

Discussion in 'Programming' started by Peuplarchie, Nov 27, 2008.

  1. #1
    Good day to you all,
    my question this time seems easy but, I dont have a clue on how to do this...

    I would like to read the directory of today...

    
    
    if ($handle = opendir('Y/m/d,time()')) {
    
    
    PHP:
    Can somebody help me in wording this ?

    Thanks !
     
    Peuplarchie, Nov 27, 2008 IP
  2. peeeev

    peeeev Peon

    Messages:
    36
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    0
    #2
    Directory name can not contain "/" char.

    So, the way to go may be this:

    
    if ($handle = opendir(date("Y.m.d", time())) {
      // do something
    }
    
    PHP:
     
    peeeev, Nov 28, 2008 IP
  3. misbah

    misbah Active Member

    Messages:
    265
    Likes Received:
    10
    Best Answers:
    0
    Trophy Points:
    68
    #3
    try this
    
    if ($handle = opendir(date("Y/m/d"))) {
      // do something
    }
    
    Code (markup):
     
    misbah, Nov 28, 2008 IP