Jump to content


Photo

Have trouble


  • Please log in to reply
3 replies to this topic

#1 massive

massive
  • Members
  • PipPipPip
  • Advanced Member
  • 40 posts

Posted 13 May 2006 - 09:38 AM

hi guys i've seem to have some trouble transfering some of my files here is the code but i know this really works but in my case does'nt... :( heres the simple code that i can't run:

If i do this:


<?
        $getting_this_file ="C:\mysql\bin\dbases.txt";
        $putting_to_this_directory ="C:\dbases.txt";

        if (!copy($getting_this_file , $putting_to_this_directory)) {
    
           print ("failed to copy into directory $getting_this_file...<br>\n");
}


?>

This is the error msg that comes out

Warning: copy(C:\mysql\bin\dbases.txt) [function.copy]: failed to open stream: No such file or directory in C:\some directory\htdocs\phpscript\copy.php on line 4
failed to copy into directory C:\dbases.txt...



Then i Added an "@" sign before copy ======> '!@copy':



<?
        $getting_this_file              ="C:\mysql\bin\dbases.txt";
        $putting_to_this_directory ="C:\dbases.txt";

        if (!@copy($getting_this_file , $putting_to_this_directory)) {
    
           print ("failed to copy into directory $getting_this_file...<br>\n");
}


?>




Then This is the error msg comes out which i did when failed of copying a certain file


failed to copy into directory C:\dbases.txt...



i'm using php version 5.0.5 and apache 2 under windows environment...im puzzled right now (X_x)


thanks

#2 massive

massive
  • Members
  • PipPipPip
  • Advanced Member
  • 40 posts

Posted 14 May 2006 - 12:46 AM

...

#3 _will

_will
  • Members
  • PipPip
  • Member
  • 25 posts

Posted 14 May 2006 - 04:51 AM

[!--quoteo(post=373477:date=May 13 2006, 05:38 AM:name=atitudeskills)--][div class=\'quotetop\']QUOTE(atitudeskills @ May 13 2006, 05:38 AM) View Post[/div][div class=\'quotemain\'][!--quotec--]
hi guys i've seem to have some trouble transfering some of my files here is the code but i know this really works but in my case does'nt... :( heres the simple code that i can't run:

If i do this:


<?
        $getting_this_file ="C:\mysql\bin\dbases.txt";
        $putting_to_this_directory ="C:\dbases.txt";

        if (!copy($getting_this_file , $putting_to_this_directory)) {
    
           print ("failed to copy into directory $getting_this_file...<br>\n");
}
?>

This is the error msg that comes out

Warning: copy(C:\mysql\bin\dbases.txt) [function.copy]: failed to open stream: No such file or directory in C:\some directory\htdocs\phpscript\copy.php on line 4
failed to copy into directory C:\dbases.txt...
Then i Added an "@" sign before copy ======> '!@copy':

<?
        $getting_this_file              ="C:\mysql\bin\dbases.txt";
        $putting_to_this_directory ="C:\dbases.txt";

        if (!@copy($getting_this_file , $putting_to_this_directory)) {
    
           print ("failed to copy into directory $getting_this_file...<br>\n");
}
?>

Then This is the error msg comes out which i did when failed of copying a certain file
failed to copy into directory C:\dbases.txt...
i'm using php version 5.0.5 and apache 2 under windows environment...im puzzled right now (X_x)
thanks
[/quote]

how are the permissions setup on your server?


#4 massive

massive
  • Members
  • PipPipPip
  • Advanced Member
  • 40 posts

Posted 15 May 2006 - 05:52 AM

solved

instead of this:

c:\some directories\file\tmp



it was change to this:


c:\\some directories\\file\\tmp




:)




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users