Questions tagged [attachevent]
44 questions
0
votes
1 answer
Dynamically created elements eventattaching with on() doesn't work
I am trying for 2-3 hours on this script. It creates ul and append li to it. Then i try to attach eventListeners (click) which will be a trigger for some function.
On my local try callback function only retrieves last li values. Is it a looping…

caglaror
- 459
- 1
- 13
- 28
0
votes
2 answers
preventDefault, make changes and continue routine
I have a small site with a script that runs a query with mysql and returns me some data, including domains. These domains are generated html links and I want to change in javascript, since I can not access the part of php, but yes to the javascript…

Anto
- 313
- 1
- 3
- 13
0
votes
1 answer
want attachEvent Replacement in win7 IE11
else {
oStatus.attachEvent("onmouseover", function(){getCoordinates(oStatus)});
oStatus.innerHTML="Status: New. Click

user3616597
- 11
- 1
- 4
0
votes
1 answer
AttachEvent of 0 is undefined
I want to automatically resize parts of my Website with the onchange-Event. But as always I got a little problem to solve.
Console gives this error:
The property undefined or a null reference can not be retrieved".
function Resize() {
var…

Armin Bu
- 1,330
- 9
- 17
0
votes
1 answer
IE8 fallback for addEventListener breaks code for modern browsers
Drawing off the explanation provided in this example, I added the following code to my html as part of an immediately invoked function expression:
(function hideOverlayOnEsc(){
document.addEventListener('keydown', function(e){
if(…

Brian S
- 121
- 2
- 15
0
votes
1 answer
Cancelling onBeforeUnload with addEventListener
I'm trying to figure out how to prevent the onBeforeUnload event from being triggered in IE9+ when using links without hrefs.
I've set up a fiddle here (a simplified test of a real scenario), which pretty much describes what I'm trying to…

stafffan
- 482
- 6
- 17
0
votes
1 answer
Upgrading to Windows 8.1 causes window.attachEvent("onload", to fail
I have a program that I use to develop web applications called CodeCharge Studio. I have just upgraded to Windows 8.1 from Windows 8 and I now keep getting an error when using the program. The error occurs in a common javascript file and the line is…

Saseow
- 25
- 5
0
votes
2 answers
How to attach a mouseenter event listener to sap.m.StandardListItem?
I need to retrieve some data attached to a standardListItem when it is dragged. I am handling the drag with jQuery-UI draggable. I did the following:
var oItemTemplate = new sap.m.StandardListItem();
oItemTemplate .bindProperty("title",…

Mohamed Ali JAMAOUI
- 14,275
- 14
- 73
- 117
0
votes
0 answers
addEventlistener and attchEvent
I have a function that targets the li elements of a div id called mk-featured-kits. All of this works perfectly.
(function() {
var myNode = document.getElementById('mk-featured-kits');
myNode.addEventListener("mouseover", function(e) {
…

Corvuslab
- 31
- 5
0
votes
1 answer
addEventListener duplicating Select Options Javascript
I created a javascript function to copy data from an input on another jQuery tab to a Summary tab. I am having an issue with duplication with a dropdown.
I need for it to replace the exisiting information when choosing another selection if a…

Sean Robbins
- 71
- 2
- 5
- 12
0
votes
2 answers
using addEventListener to live copy to a summary page, running into a bit of an issue
I'm a javascript/jQuery No0b and looking to use the addEventListener to print progress in a summary page. this is a 4 tabbed form.
HTML:
![]()
Sean Robbins
0
votes
1 answer
What's the difference between these two addEvent functions?This is the first:
function addEvent(el, type, fn){
if(el.addEventListener){
el.addEventListener(type, fn, false);
}else{
el[fn] = function(){
fn.call(el, window.event);
}
el.attachEvent('on'+type,…
![]()
Tom Tom
-1
votes
2 answers
javascript addEventListener firing on all elementsIm sure I have missed something obvious but any idea why the following addEventListener code is firing everywhere (on not just on the submit button)?
HTML:
![]()
Adi
-4
votes
1 answer
Will IE10 use `addEventListener`, or `attachEvent`?Will it still be evil and headbangingly frustrating and quirky like the others so far? When are they just going to get with the program, or will they ever? Personally, I hope they don't so that people abandon them for free software sooner, and that…
![]()
wwaawaw
|