Questions tagged [uncaught-reference-error]
57 questions
2
votes
0 answers
woocommerce_admin is not defined
I am getting one error in wordpress admin console - " Uncaught ReferenceError: woocommerce_admin is not defined "
I can't figure it out why I am getting this error.
Wordpress version - 5.9
WooCommerce version - 6.4.1

Nima Murali
- 86
- 5
2
votes
2 answers
Uncaught Reference error require not defined in javascript
Hello i am beginner in JavaScript. I am trying to access the functions of user.js in script.js but it is throwing error i have attached ss also, and below is the implementation of what I am doing.
I have create 4 files
index.js (starting…

Sachin
- 55
- 1
- 5
2
votes
1 answer
How do I fix an uncaught reference error for this TicTacToe
I am doing a HTML, CSS, JSS tictactoe project, and I have run into an error where the console ribbon/section (when right clicking and going to "inspect" in browser) has stated the following when I tried using the console.log in my text editor:
…

KO-d14
- 115
- 7
2
votes
0 answers
Problem in WordPress with a onclick event, showing an Uncaught Reference Error
I have a survey on a website (WordPress, zenith template) and I have a problem submitting the form. I get an error saying "Uncaught Reference Error". Can someone help me fix this problem?
Screenshot from the moment y click SEND button
The survey…

Sebastián Contreras
- 21
- 4
1
vote
1 answer
How to make Highcharts work inside an Electron App?
HTML document:
In a renderer js file: Highcharts.chart('graph', {...});
The main.js looks like this:
win = new electron.BrowserWindow({
width: config.width,
height: config.height,
backgroundColor:…

cu 29p
- 11
- 2
1
vote
0 answers
Script cannot get calculate with element assigned to const
I'm trying to modify a cart of a shopify store. It's using a bundle application, which overwrites the prices in the cart, hence I'm trying to get those overwrited prices and calculate with those, in order to be able to display how much the customers…

Strikementos
- 68
- 5
1
vote
1 answer
Trying to import in typescript file. (export is not defined)
Full error:
Uncaught ReferenceError ReferenceError: exports is not defined
at (c:\Users\user\Documents\vsCode\Slider\src\script.js:2:23)
@ c:\Users\user\Documents\vsCode\Slider\src\script.js:2:23
I have spent around 3 hours searching for anything…

bakerBite
- 41
- 5
1
vote
0 answers
I pass a variable to ejs but still throw Uncaught ReferenceError why?
I pass a productId but still get Reference error in ejs why is that happening?
Script in frontend:
Another Try:
if(typeof <%= productId %> != "undefined"){
const…

AssSoonAsPossiblee
- 165
- 2
- 11
1
vote
1 answer
"Uncaught ReferenceError: printMe is not defined" at onload method in HTML
I'm currently trying to get started using webpack and ran into "Uncaught ReferenceError: printMe is not defined" error when trying to call my "init" method from HTML using the onload tag despite exporting the methods. My files are as…

Jack Gitter
- 43
- 1
- 7
1
vote
2 answers
Why is const variable localQuotes not defined in this random quotes generator?
Problem explained more clearly here:
I am creating a simple random quote generator using JavaScript. I have hundreds of quotes in an array in a file called "quotes.js" and then the actual function to make it work in a file called "script.js" which…

Joe
- 21
- 3
1
vote
2 answers
Uncaught Reference Error: gapi is not defined
So I'm trying to experiment with accessing my google spreadsheet using JS, and I'm a beginner, and probably way in over my head, but I need help
So I have this script
Google Sheets API Quickstart
…

Weatherby Syriux
- 41
- 2
1
vote
1 answer
Angular typescript gives reference error when implementing subclasses to abstract class
I get the current error:
Uncaught ReferenceError: can't access lexical declaration 'AbstractClass' before initialization
when doing this in a new Angular project:
@Component({
selector: 'app-root',
templateUrl: './app.component.html',
…

Payerl
- 1,042
- 2
- 16
- 33
1
vote
1 answer
PHP Fatal error: Uncaught Error: Call to undefined function
I have recently migrated from the old PHP5xx to PHP7.4.23 version and below is the error message when localhost URL is tested. I can confirm the index.php has reference to include rightbar.php from the same folder destination. If I remove the…

Neville
- 11
- 1
- 3
1
vote
1 answer
JS function within external js file cannot be called - Uncaught reference error
I have a small form that should run a js function when the submit button is clicked. Unfortunately, I keep getting an error in the console whenever the submit button is being clicked, that the function is not defined. The script file containing the…

DNYX
- 43
- 6
1
vote
1 answer
Unexpected token else
I have encountered a Syntax error in my javascript code. I'm getting a message of 'Unexpected token else' error.
I hope someone can help me with this. Here is my code:
function doRed() {
for (var pixel of img.values()){
var avg =…

Alexis Harrison
- 11
- 2