?
Solved

OpenDir: Invalid argument

Posted on 2004-08-09
1
Medium Priority
?
600 Views
Last Modified: 2013-12-13
I'm trying to get working following code:

$path = "C:\\@\\";
$dp = opendir($path);

and get following error:

OpenDir: Invalid argument (errno 22)

Any chance to make it working with '@' character in path?

TIA,
dumb
0
Comment
Question by:iam_dumb
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 3

Accepted Solution

by:
thecode101 earned 800 total points
ID: 11763184
Try this:
$dp = opendir('c:/@');

I tested it using the following script and it worked correctly:
<?php
if ($handle = opendir('c:/@'))
{
      while (false !== ($file = readdir($handle)))
         {
              if ($file != "." && $file != "..")
                  {
                        echo $file;
              }
       }
}
else
      echo "Unable to Open Folder";
?>
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Since pre-biblical times, humans have sought ways to keep secrets, and share the secrets selectively.  This article explores the ways PHP can be used to hide and encrypt information.
This article discusses how to implement server side field validation and display customized error messages to the client.
The viewer will learn how to count occurrences of each item in an array.
The viewer will learn how to look for a specific file type in a local or remote server directory using PHP.
Suggested Courses

741 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question