• Resolved wpuser10

    (@wpuser10)


    When I am using the following code then import works fine (without any errors):

    $slider_array = array(
        get_template_directory()."/dummy/slider_1.zip"
    );
    $slider = new RevSlider();
    foreach($slider_array as $filepath) {
        $slider->importSliderFromPost(true,true,$filepath);  
    }

    but when adding one more correct slider to the array then during import using “One Click Demo Import” plugin there is showing “Error: Internal Server Error (500)”

    $slider_array = array(
        get_template_directory()."/dummy/slider_1.zip",
        get_template_directory()."/dummy/slider_2.zip"
    );
    $slider = new RevSlider();
    foreach($slider_array as $filepath) {
        $slider->importSliderFromPost(true,true,$filepath);  
    }

    Do you know how to implement it in the best way to make it working with “One Click Demo Import”?

    Code example based on:
    https://www.themepunch.com/faq/theme-authors-auto-import-slider-demos/

    • This topic was modified 7 years, 10 months ago by wpuser10.
    • This topic was modified 7 years, 10 months ago by wpuser10.
    • This topic was modified 7 years, 10 months ago by wpuser10.
Viewing 1 replies (of 1 total)
  • Plugin Author Gregor Capuder

    (@capuderg)

    Hi,

    did you try to run this code on theme load (in functions.php for example, just so you know, that it’s working ok)?

    The only thing that comes to mind, that could cause the 500 server error (if the code is working correctly), is that the server runs out of memory or the max_execution_time is reached.

    Please check your PHP error logs on your server and see, what kind of error was triggered.

    Take care!

Viewing 1 replies (of 1 total)
  • The topic ‘Internal Server Error during importing sliders’ is closed to new replies.