SitePoint Sponsor

User Tag List

Results 1 to 3 of 3
  1. #1
    SitePoint Enthusiast AimyThomas's Avatar
    Join Date
    Sep 2011
    Posts
    46
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)

    File upload problems

    When I upload image files they have the same extension twice. And my script doesn't show it even it the path is correct.

    Some scripts copy the file from the tmp dir server to the required directory, while others just move it. What happens to the files that were just copied? Do they stay there or does the server remove them?

    Thanks in Advance

  2. #2
    SitePoint Member blogaddition's Avatar
    Join Date
    Sep 2012
    Location
    India
    Posts
    23
    Mentioned
    2 Post(s)
    Tagged
    0 Thread(s)
    could you post the code that you have used in your script.

  3. #3
    Hosting Team Leader silver trophybronze trophy
    cpradio's Avatar
    Join Date
    Jun 2002
    Location
    Ohio
    Posts
    5,142
    Mentioned
    152 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by AimyThomas View Post
    When I upload image files they have the same extension twice. And my script doesn't show it even it the path is correct.
    We would need to see your upload code to help debug that issue.

    Quote Originally Posted by AimyThomas View Post
    Some scripts copy the file from the tmp dir server to the required directory, while others just move it. What happens to the files that were just copied? Do they stay there or does the server remove them?
    This is dependent on what the server you are running on uses as the temp directory for uploads set in the php.ini file. Most servers using the Operating System /tmp folder. That folder is cleared out on reboot of the server (sometimes on a schedule as well), so they will not be persisted. If the host choose a different folder to store the uploaded files temporarily, then the host would have to create its own purge for that folder too, otherwise, the files would be kept.


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •