Support » Plugin: HD Quiz » CSV Import Error

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Harmonic Design

    (@harmonic_design)

    Hi itumahi,
    thank you for taking a look a the console.

    It looks like the real issue is Uncaught ReferenceError: HDQ is not defined which is interesting because it essentially means that HD Quiz isn’t loaded on that page. I cannot tell you why this would be happening for you, but something on your site is messing with enqueued scripts in your admin area.

    Another possibility is that your site is just too damned slow. By this, I mean that the importer is trying to send the data for the next question before HD Quiz has fully initialized.

    STEPS:
    First, let’s make sure that this is not a timing issue due to a super slow site/server.

    Edit ./hd-quiz/includes/tools/csv_import.php and replace line 278 near the very bottom with the following:

    echo '<script>setTimeout(function(){HDQ.parseNext("'.$csvFile.'", '.$atonce.', '.count($csvAsArray).');}, 5000);</script>';

    This will slow the process down 500%, giving your server plenty of time to load everything. Make sure to clear your browser cache after saving 🙂

    If the above does not work for you, then based on your reply to a similar past thread

    It used to work before. But not anymore.

    Code is code and the same code executes the exact same way every time – zero exceptions. So if it used to work, but doesn’t anymore, then this means that the cause is that something has changed on your site. So the only / best advice I can give is to try and track down what changed on your site so we can find the culprit.

    The standard WordPress debug procedure is the following. This is used to narrow down any possible conflicts from other plugins or your theme.

    1. Switch theme to the default Twenty Twenty theme. Clear your browser cache and try again. If it now works, then we know that the issue lies with your theme.
    2. If it is not your theme, then we need to test plugins. Deactivate all plugins except HD Quiz then test again. Then re-enable each plugin one by one until we find the culprit.

    If all of the above still fails you, then my best next best guess is that your server is misconfigured and is experiences disconnects. Basically the connection between your site and your server gets interrupted which breaks the connection. If this is the case then you will need to contact your host to get them to debug/fix your server.

    I’m marking this thread as resolved simply because I cannot think of anything else that could help or be the cause, but please do not hesitate to reply to this thread again with updated information or if you need further assistance or clarification on anything.

    Hello Harmonic Design

    Thanks a lot for the quick response.

    I did update the line (just incremented the milliseconds from 1000 to 5000). It is working now 🙂 It is spot on.

    Really impressed by the plugin and the support. Nowadays, we can’t expect this even from the so called paid pro/premium versions.

    Great job. Keep going.

    I will also poke my hosting provider to improve the speed.

    Thanks again.

    litumahi

    (@litumahi)

    Hi

    Just to update on this. The issue was actually with the ‘Bluehost’ plugin. I deactivated it and have done the above change (1000 ->5000). So got confused. When I activate the Bluehost plugin, I saw that error again. So I guess, the issue is with the plugin compatibility.

    Thanks

Viewing 3 replies - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.