I am getting a “Empty string passed to getElementById()” error on page load(on every page of our companies website) when using Firefox(but not in Chrome) in the web console. Originally I thought it was because of a specific form on a specific page of our website but now I am not to sure as it is generated on any page load. I have attached a couple of files, 3 screenshots of what it is doing on different pages, and a .js file that is referenced.
I think it might be generated from a few lightboxes that are on the website however, no lightboxes are called until form submissions happen.
Anyone have any ideas as to why I am getting this error and what could/would be causing it?
I can post my code/attach to this if you would like. I don’t have it currently posted since it is about 400 hundred lines across multiple pages as well as back end.
.js file won’t upload so I guess I will paste it as a code block. I have posted the function below. Lines 120 and 125 are
Was a common problem in older versions of Firefox, simply put ‘Empty string passed to getElementById()" error’ into Google and read the long list of posts that get displayed!
Although without seeing all of your code etc, we can’t confirm that it is caused by a Firefox bug and we can’t rule out issues somewhere with your code etc.
However, we don’t also want you pasting up multiple lines of code and it all getting confusing, so it might be better and easier if you can simply paste up your Wix Editor URL so that Wix Admin or Mods can then use that to check your website and go through your code for you to double check it.
@yisrael-wix or whoever else is on to look at this.
Only Wix Admin and Mods from this forum have the permissions to access your Wix Editor, so it is safe to post it up instead of copying and pasting all those lines of code.
Please post the editor URL of your site. Only authorized Wix personnel can get access to your site in the editor.Please include the name of the page involved.
@givemeawhisky Thanks for your response. I was assuming it was a Wix thing as it appeared to not show up until some code later that was added. I am going to look through the links you posted so I can get a better grasp as to what it is doing.
The only code being used that even deals with html elements is simply to grab the values from the fields using
I first noticed this issue when editing and testing the “7Cs” page but there are forms also on “Maze Map” and " Parent/Guardian Permission Form" both the old and new pages.
@jmanoa1570 The messages that you’re getting are warnings and not errors. Is something not working properly on your site? Does the site “behave” differently when running on Firefox?
@yisrael-wix Everything appear to be working fine. I just wasn’t sure what was going on to have generated so many warnings and why it was only showing up in firefox. Is it correct for me to assume this is only a firefox thing and to not worry about it?