SitePoint Sponsor

User Tag List

Results 1 to 9 of 9
  1. #1
    SitePoint Member
    Join Date
    Apr 2011
    Posts
    12
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Issue with File Upload

    I am struggling to find the answer to my problem through any forum or Google search (probably because I am not well-versed in server language or settings.

    I have a basic file upload form...

    Code:
    <form action=http://www.thelogoapproach.com/Admin/updateInventory.php method=post enctype="multipart/form-data">
    <input type="hidden" name="MAX_FILE_SIZE" value="400000" />
    Inventory File:&nbsp;&nbsp;&nbsp;<input name="inventory" type="file">
    <br><br><input type=submit value="Upload Inventory">
    </form>
    When I click submit to the form, the browser just keeps "processing" and updateInventory.php never loads (nor do I get any errors at any point). updateInventory.php is in a protected folder, but it is the same folder that this form upload is located in.

    The file that I am trying to upload is a .csv file that is only 310KB.

    Does anyone know what I may be doing wrong?

  2. #2
    SitePoint Mentor silver trophy
    Rubble's Avatar
    Join Date
    Dec 2005
    Location
    Cambridge, England
    Posts
    2,364
    Mentioned
    80 Post(s)
    Tagged
    3 Thread(s)
    Why not do a test by putting your code into an unprotected folder and see what happens?

  3. #3
    SitePoint Member
    Join Date
    Apr 2011
    Posts
    12
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    So initially I got the same results...

    At the bottom of the browser it says, "Waiting for www.thelogoapproach.com..." after "Sending Request to www.thelogoapproach.com...".

    9 out of 10 times, it does that and just keeps processing. 1 out of 10 times it will work.

    Would there be anything on my own personal computer that would be slowing down the upload or connection (the 1 time it works, it goes quickly)?

  4. #4
    SitePoint Mentor silver trophy
    Rubble's Avatar
    Join Date
    Dec 2005
    Location
    Cambridge, England
    Posts
    2,364
    Mentioned
    80 Post(s)
    Tagged
    3 Thread(s)
    Try adding this to the top of the updateInventory.php file and see if it displays any errors.

  5. #5
    SitePoint Member
    Join Date
    Apr 2011
    Posts
    12
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I do not see what you are wanting me to add.

  6. #6
    SitePoint Mentor silver trophy
    Rubble's Avatar
    Join Date
    Dec 2005
    Location
    Cambridge, England
    Posts
    2,364
    Mentioned
    80 Post(s)
    Tagged
    3 Thread(s)
    Woops

    PHP Code:
    error_reporting(E_ALL); 

  7. #7
    SitePoint Member
    Join Date
    Apr 2011
    Posts
    12
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    When I executed it in the unprotected file today, it worked on the first try. I did not get any error messages though.

    Any ideas on what CHMOD settings I would need on this directory or how I could get it to work with the current (755) settings?

  8. #8
    SitePoint Member
    Join Date
    Apr 2011
    Posts
    12
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    And the second time that I tried executing it with a script to connect to mysql and ftp that was previously located in the protected folder as well, the problem came back.

  9. #9
    SitePoint Member
    Join Date
    Apr 2011
    Posts
    12
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Any ideas?


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
  •