User is not able to vote. Errors in console

There are typical errors which might occur due to 3rd party extensions. E.g. users are not able to vote for entries and there are numerous errors in browser's console. What to do?

Let's consider the following scenario:

When a user tries to vote as a guest (not registered) user, there is the following error in the console:

Uncaught ReferenceError: Competition is not defined onclick

However, the user can vote as a registered user. Why so?

This error occurs because of using 3rd party extension which optimizes scripts.

NorrCompetition component loads minified script and when 3rd party extension tries to compress a file which is already compressed, it leads to potential and real issues.

If your website has JCH Optimize extension which is configured and running, then please include competition.min.js file to excludes list as it does not work when combined by JCH optimize.

The better approach for stable perfomance of NorrCompetition component is to use "Excluding files from a particular extension" and exclude all "com_competition" Javascript files.

See JCH Optimize documentation: Chapter 5. Optimizing Your Site With JCH Optimize (Procedure 5.1. Excluding files and inline scripts)

Last updated