• Hello,

    When i force the /wp-admin/ to be https with a redirect in apache22 conf the uploads function is not working anymore and some of the functions like deleting a page/post from the admin only work when i choose edit from viewing the page/post logged in as admin.

    Is there no https support? It seems to me a bit weird we get forced to use our usernames/passwords in an unsafe manner..

    Tnx in advance!

Viewing 1 replies (of 1 total)
  • I ran into the same problem and fixed it (somewhat dirty) by editing wp-admin/includes/media.php, i changed the line 841 from

    $form_action_url = get_option('siteurl') . "/wp-admin/media-upload.php?type=$type&tab=type&post_id=$post_id";

    to

    $form_action_url = "/wp-admin/media-upload.php?type=$type&tab=type&post_id=$post_id";

    this changes the upload form action-url from an absolute to a relative one, the (stupid) absolute url had https://.. (without s) hardcoded. this then leads to an uploading error when submitting the form, because apache rewrites the request and sends a code 302, which generates another request to the correct url (with s) but, strange, without POST data.

    see my fix as “worksforme”, there might be a better solution. for example to exclude /wp-admin/media-upload.php from being rewritten by apache (but then the uploads will not be transmitted securely).

    edit: this is for wordpress 2.5.1

Viewing 1 replies (of 1 total)
  • The topic ‘Uploads not working when forcing https ( redirect )’ is closed to new replies.