Current location: Hot Scripts Forums » Programming Languages » PHP » Help with opendir


Help with opendir

Reply
  #1 (permalink)  
Old 12-20-05, 09:56 AM
connor connor is offline
Wannabe Coder
 
Join Date: Apr 2005
Location: Knob Noster, Mo
Posts: 228
Thanks: 1
Thanked 0 Times in 0 Posts
Help with opendir

Ok so I am using this with a dropdown... It works if there is just one file name (i.e. dev) it will read that dir but if I do ./theme it doesn't work please help.

PHP Code:

if ($handle opendir('../theme')) {

   while (
false !== ($file readdir($handle))) { 
    if (
$file != "." && $file != "..") { 
       
$opt .= "<option value='".$file."'>".$file."</option>";
    }    
   }
   
closedir($handle);

Reply With Quote
Reply

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Problem with handle on opendir !!BUBBLES!! PHP 4 09-25-03 07:48 AM


All times are GMT -5. The time now is 06:23 AM.
vBulletin® Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.