Home / Forum / Javascript focus() and submit() problem!

Javascript focus() and submit() problem!

Nächstes Thema

Um Zugang zu den Foren zu erhalten, müssen Sie angemeldet sein

Autor Nachricht

kevin spade

Registriert seit: 27.06.2018

Beiträge: 3

Donnerstag, 28. Juni 2018 09:41:36


I have come across 2 problems using FF 29.0.1 that I can't figure out and I'm looking for some help:
1.) When my page loads I have js code 'document.getElementById('dbtype').focus();' that should set focus to the first element. The element is a <select> tag and according to the tab order it does have focus (I can tab and I do go to the next element). However, there is no indication that the element has focus, like dotted lines, or anything. IE8 does show focus by having dotted lines inside the element. Why does FF not show this also?
2.) I use js code 'document.getElementById("cefiform".submit();' to submit the form but Firebug tells me that submit() is not a function. If I remove the () character then I do not get any errors but the form does not submit. Why?

Please help.

I didn't find the right solution from the Internet.

<a href=https://blog.advids.co/20-operati...deo-marketing-examples/>Operation Management Service Video</a>



Um Zugang zu den Foren zu erhalten, müssen Sie angemeldet sein