Copy function not working

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • maheswaran
    New Member
    • Mar 2007
    • 190

    Copy function not working

    Hi,

    I copy the file from local to server using "Copy" function.
    see
    Copy($localfile ,"Document/01/$file)

    The number 01 is incresing dynamically according to number of files in a folder. If folder "01" have 9 files than new local files is copied in to directory 10. The directory 10 is created while use the copy function

    Copy($localfile ,"Document/01/$file")

    What my problem is this work in my system and not work in another system. Both system have "xampp" installed and we are in admin login. What is the Problem?.

    I have rectified tis problem using mkdir... If there is no directory (ie 10) then it creates and after copy action is follow up


    If this cause of permission problem then how mkdir is working?....
  • Atli
    Recognized Expert Expert
    • Nov 2006
    • 5062

    #2
    This sounds like a permission problem, although the fact that the mkdir function is working would suggest otherwise.

    What error are you getting?
    What type of permission do you have on the file? (see fileperms)

    Comment

    • maheswaran
      New Member
      • Mar 2007
      • 190

      #3
      Am not get any error. But files are not copied.

      And i have checked both machine i got "0777" using fileperms function.

      Comment

      • Atli
        Recognized Expert Expert
        • Nov 2006
        • 5062

        #4
        Are there any differences between the servers?
        Are they running on the same type of OS? The same versions?

        Are there differences in the Apache / PHP versions?
        Any major differences in the server configuration?

        Is there anything else worth mentioning that may help us dissect this problem?

        Comment

        • maheswaran
          New Member
          • Mar 2007
          • 190

          #5
          My Machine Hosted in to Windows Xp (local)

          And Another system is client system ,hosted into windows xp.

          And Client server is in windows server.

          No Differnece in Apache/PHP/Mysql

          Comment

          Working...