• Resolved KTS915

    (@kts915)


    First of all, may I say thanks for being (to my knowledge, at least) the first person on www.ads-software.com to create a quiz plugin that uses custom post types! This is surely how it should be done!

    Second, though I’ve only been playing with this for a day, you’ve already added pagination! Thanks again!

    But I do have two problems:

    1. In your hd-quiz/admin.css file, you have this on line 5: @import url(https://fonts.googleapis.com/css?family=Open+Sans) !important;

    That seems unnecessary to me. Indeed, when I comment it out, the plugin works fine and the site goes faster. Could you consider omitting this line in future, please?

    2. The file hd-quiz/custom.js causes a problem when compressed (minified) using ZenCache Pro. This is pretty unusual so, while I can add a line to exclude it from being minified, I am wondering whether there is a latent issue here.

    Thanks for reading this.

    https://www.ads-software.com/plugins/hd-quiz/

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

    (@harmonic_design)

    Hello, KTS915, and thanks for your support; means a lot!

    1. Open Sans font.
    You are ABSOLUTELY right about this one, there really is no reason I should be forcing this. It’s a latent CSS import from ~a week ago that flew under the radar. I’ll have it removed from the trunk and next update of HD Quiz.

    2. custom.js minification
    Currently, I have no idea why minifying custom.js would cause any problems – it should all be good. I’ll do some debugging on my end to see if there is a particular line or variable causing this failure when minifying (who knows, may even be ZenCache specific), and push an update.

    I’ll mark this topic as resolved once I find a solution.

    Thanks for this post – I can’t bug test HD Quiz against every theme/plugin combo by myself!

    All the best,
    ~Harmonic Design

    Thread Starter KTS915

    (@kts915)

    Wow, that was fast! Thank you!

    I have played with pagination a bit more, and I now see that the plugin changes the question number, but keeps re-using the same question on every page. Maybe that’s a clue as to what the issue with the JS minification might be.

    Plugin Author Harmonic Design

    (@harmonic_design)

    haha, it’s marked experimental for a reason ??

    It sounds like your theme is unable to accurately retrieve the $paged variable so that it knows what questions were on the last page and which are coming up.

    If it’s OK with you, I’d love to see a live example.

    Thread Starter KTS915

    (@kts915)

    Well, showing you a live example is a bit tricky, as this is only on localhost at the moment.

    But I think I have found the problem. On line 166 of hd-quiz/template.php, you have wp_reset_postdata();

    I believe this should be wp_reset_query();

    At any rate, this seems to make the questions change as they should. (It doesn’t solve the JS minification issue, though.)

    Plugin Author Harmonic Design

    (@harmonic_design)

    That would have been the first thing I’d have asked you to check, glad to know that was it for you ??

    I’ll most likely push a minor update this weekend. On the menu:

    • removal of google font
    • updates to pagination
    • hopeful ZenCache compatability
    • While we’re on the topic of speed, I’ll extend my HD Quiz detection class to only enque the custom.js on pages where HD Quiz is being used (wish more plugins would do this!)

    Thank you for all, you’ve been a real help!

    All the best,
    ~Harmonic Design

    Thread Starter KTS915

    (@kts915)

    Thank you very much. This all sounds great: you are 100% right about enqueuing styles and scripts only when necessary.

    As for the JS minification issue, you’ll need the Pro version of Zen Cache (which costs money) so, if you don’t already have it, please don’t go to that expense on my account. (I don’t know if the minification issue is present with other minification plugins because I don’t use them.)

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Looks very promising, but a couple of problems’ is closed to new replies.