Title: execute javascript on result page
Last modified: June 9, 2022

---

# execute javascript on result page

 *  Resolved [Antonio Lupo](https://wordpress.org/support/users/antoniolupoime/)
 * (@antoniolupoime)
 * [4 years ago](https://wordpress.org/support/topic/execute-javascript-on-result-page/)
 * Hi, I’d like to execute some JS or jQuery code on the result page, to insert 
   html code dinamically depending on score points.
    Quiz pages are loaded by Ajax
   so if i put script code in quiz page, it executes on first quiz pages. Is there
   a way to trigger my scripts just on result page? Thank you

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

 *  [sumitsanadhya](https://wordpress.org/support/users/sumitsanadhya/)
 * (@sumitsanadhya)
 * [4 years ago](https://wordpress.org/support/topic/execute-javascript-on-result-page/#post-15724054)
 * Hi Antonio,
 * I need to discuss this with my development team. Hopefully, I will get back to
   you with the solution.
 * Regards,
    Sumit
 *  [sumitsanadhya](https://wordpress.org/support/users/sumitsanadhya/)
 * (@sumitsanadhya)
 * [3 years, 12 months ago](https://wordpress.org/support/topic/execute-javascript-on-result-page/#post-15727208)
 * Hi Antonio,
 * I don’t think there is a need to use JavaScript in this case.
 * You can use conditions on the results page to show the HTML content you want,
   depending on the points. Please check the below-given screenshot link for your
   reference.
 * [https://app.usebubbles.com/2BqL9XkThnSKCFEnFCU3yo/untitled-bubble](https://app.usebubbles.com/2BqL9XkThnSKCFEnFCU3yo/untitled-bubble)
 * Let me know if you need more help.
 * Regards,
    sumit
 *  Thread Starter [Antonio Lupo](https://wordpress.org/support/users/antoniolupoime/)
 * (@antoniolupoime)
 * [3 years, 12 months ago](https://wordpress.org/support/topic/execute-javascript-on-result-page/#post-15731289)
 * of course i know about this feature, i already use it to show different messages,
   but I need to show something that is not in your plugin:
    – a percentage score
   point value (e.g. (%POINT_SCORE% / %MAXIMUM_POINTS%) * 100), since %CORRECT_SCORE%
   gives just correct answers percentage – a progress bar indicator to show graphically
   to user his percentage score, even for single category.
 * To do this, i thought i can pick values from result text and build in js what
   i need to append. I could use filters or hooks if they could help, but documentation
   about them is very poor
 *  Thread Starter [Antonio Lupo](https://wordpress.org/support/users/antoniolupoime/)
 * (@antoniolupoime)
 * [3 years, 12 months ago](https://wordpress.org/support/topic/execute-javascript-on-result-page/#post-15732349)
 * Update for those who will search for a solution: I solved by using jQuery(document).
   ajaxComplete() to execute front end code in results page.
 * thank you anyway.

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

The topic ‘execute javascript on result page’ is closed to new replies.

 * ![](https://ps.w.org/quiz-master-next/assets/icon-128x128.png?rev=3158087)
 * [Quiz and Survey Master (QSM) - Easy Quiz and Survey Maker](https://wordpress.org/plugins/quiz-master-next/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/quiz-master-next/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/quiz-master-next/)
 * [Active Topics](https://wordpress.org/support/plugin/quiz-master-next/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/quiz-master-next/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/quiz-master-next/reviews/)

 * 4 replies
 * 2 participants
 * Last reply from: [Antonio Lupo](https://wordpress.org/support/users/antoniolupoime/)
 * Last activity: [3 years, 12 months ago](https://wordpress.org/support/topic/execute-javascript-on-result-page/#post-15732349)
 * Status: resolved