Click here to Skip to main content
13,831,956 members
Rate this:
Please Sign up or sign in to vote.
See more:

Have an issue in a HTML tag where the script source is not loading. Also the problem with a Reference Error: unidentified method showing in console where a button call-back event is not responding.

ReferenceError: inputAccept is not defined

function anputAccept() {//statements here };
<--this method is not found/initalized?

I've been stuck on this for 3 hours now. Could anyone explain how and why a Reference Error/Failed Load can occur, and how to fix it so the script can load? This would not only be helpful to me, but also to others that come across a similar problem in future.

I'm suspecting it has something to do with the DOM/OBJECT configurations inside the HTML, as the script has been ran through several different analyzers with 0 produced errors (including code-pen). So as the .js file looks clean so far, there is issue with the event/method call-back configuration part.


What I have tried:

-Moving the script from tags to bottom tags
-Changing the use of addEventListener in .js and migration to HTML using .
-Diagnosing the .js through console and JSLint
-Re-formatted the JS file to run fewer scripts and use fewer but more efficient reusable variables.
-Re-tested script through several different analyzers.
Updated 16-Sep-18 2:01am

1 solution

Rate this: bad
Please Sign up or sign in to vote.

Solution 2

Got it to work with


in the EventListener

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
Top Experts
Last 24hrsThis month

Advertise | Privacy | Cookies | Terms of Service
Web01 | 2.8.190114.1 | Last Updated 16 Sep 2018
Copyright © CodeProject, 1999-2019
All Rights Reserved.
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100