Forum Replies Created

Viewing 3 replies - 1 through 3 (of 3 total)
  • Thread Starter Zaidy89

    (@zaidy89)

    @doublesixx that’s the code for the file.php, it’s not the code for the nextgen files. you can find the move_uploaded_file method in the following file for the nextgen gallery
    /wp-content/plugins/nextgen-gallery/admin/functions.php (2 x)

    @photocrati unfortunately it’s not really a good solution 😉 I have some other problems with my webspace and so I can’t update my current wordpress version to 3.6. the service team of my provider is checking the problem. but the main issues is that the site is running on a windows server. I read that v 2.0.x is only provided for 3.6. and in the backend there is no update shown for the version 1.9.13.
    when I’m able to update the wordpress to 3.6 (hopefully next week) I can tell you I the problem still exists. however the service guy told me that it’s a windows server and PHP problem with this specific method. therefore I think that a update won’t bring a solution.

    Thread Starter Zaidy89

    (@zaidy89)

    really? for me it works! the following code is now in my file.php

    // Move the file to the uploads dir
    $new_file = $uploads[‘path’] . “/$filename”;
    //if ( false === @ move_uploaded_file( $file[‘tmp_name’], $new_file ) )
    if ( false === @ copy( $file[‘tmp_name’], $new_file ) )
    return $upload_error_handler( $file, sprintf( __(‘The uploaded file could not be moved to %s.’ ), $uploads[‘path’] ) );

    Thread Starter Zaidy89

    (@zaidy89)

    finally found a solution. it’s a permission error caused by the windows server when using the method move_uploaded_file. the problem also exists when I use the standard wordpress image upload.
    simply exchange the method by using the method copy.

    for example:
    wp-admin/include/file.php
    //if ( false === @ move_uploaded_file( $file[‘tmp_name’], $new_file ) )
    if ( false === @ copy( $file[‘tmp_name’], $new_file ) )

    do the same in the nextgen plugin and everything will work fine. the bad thing is that you have to replace it everytime you update wordpress or the plugin

Viewing 3 replies - 1 through 3 (of 3 total)