Security is important, this is why one of the security requirements for HD Quiz to upload a file is to check the file’s mimetype to help ensure that the file you are uploading is not malicious.
Under the PHP Configuration heading of the documentation for this feature (found here: https://hdplugins.com/learn/documentation/hd-quiz-documentation/#hd_i-have-a-problem-with-the-csv-importer) you will find additional information about what your specific problem likely is.
In short: I need to check for the mime type of the file uploaded for security, and your server does not have the PHP extensions required to do so (note: almost every server will have these extensions enabled by default).
Your options are to either:
- A) RECOMMENDED: Activate the missing extension (likely the
fileinfo PHP extension)
- B) Modify HD Quiz to bypass the mimetype check (you can do this by editing
hd-quiz/classes/csv-import-tool.php and comment out/remove line 133 $this->validateFileType();
Thank you for the help 🙂
i did both things. checked the box extension in “Select PHP Version” in cpanel to allow this file type. you know what nothing happend. (upload file button is unclickable now).
then i tried the step 2 provided by you and stroke out the line 133 from the code. this time too same result. button is unclickable (neither it uploads nor it send the message)
we are almost there.. just help me a bit
It’s 100% impossible for either of those above changes to affect the clickability of a button.
You must have something else broken on your site setup/server (for example, I see that your SSL certificate is down at the moment, and the homepage provides a 403 Forbidden error – assuming this problem is on the “mcqs” site you previously posted).
Beyond what I’ve already recommended, all I can offer more is general debugging steps. Clear all of your caches (browser, site, host, dns, anything else), and do the basic WordPress debug steps (disable all plugins except HD Quiz, use a default WordPress theme, check to see if uploads are still broken for you).