Forums

[resolved] PDF Upload failing (5 posts)

  1. Warren Harrison
    Member
    Posted 3 years ago #

    I am unable to upload PDFs (images work with no problem) via the media uploader. The upload occurs, the file does get uploaded to the server, but the file never displays in the media library.

    In the Apache log file I see the following errors:
    - PHP Warning: array_keys(): The first argument should be an array in /sites/wp-includes/post.php on line 2568
    - PHP Warning: asort() expects parameter 1 to be an array, null given in /sites/wp-includes/post.php on line 952

    Oddly, this exact same WordPress installation works with no problem on a different server. Both are running PHP 5.2.6

    Anyone with ideas?

  2. moshu
    Member
    Posted 3 years ago #

    but the file never displays in the media library.

    Mine didn't show it either until I realized that by default it displays only the images - I had to click an "All types" to see it.

  3. Warren Harrison
    Member
    Posted 3 years ago #

    My apologies, I should have been more specific. I do see the uploaded PDFs listed under Manage > Media Library (but cannot edit their details). I do not see the PDFs in the media library accessed via the file uploader though, and therefore am unable to add them to posts.

    So, that fact that I cannot access/edit the details of uploaded PDFS (e.g. title) together with the PHP error messages tells me something is going wrong.

  4. Warren Harrison
    Member
    Posted 3 years ago #

    My issue was resolved by re-downloading 2.6.2 and performing the upgrade again. It seems that the 2.6.2 files I previously downloaded had some older files mixed in.

  5. La M
    Member
    Posted 3 years ago #

    Hi

    I'm confused, I successfully uploaded a pdf file to the media library, but when I add a media file to the post all I get is the pdf title as text, no link to a file.

    What is the process?

Topic Closed

This topic has been closed to new replies.

About this Topic