click - mootools | toggler event

I have mootools code:document.getElements('.toggler').addEvent('click', function(e){var target = this.getChildren('i');console.log(target);if (target.hasClass('icon-minus')) { console.log('hasclass - minus'); target.addClass('icon-plus').removeClass('icon-minus'); this.getNext('div').hide();} else { console.log('hasclass - plus'); target.addClass('icon-minus').removeClass('icon-plus'); this.getNext('div').show();} });My HTML layout:<div class="filter"> <sup class="toggler"> <i cl...Read more

How to send Keyboard events (e.g. Backspace, Delete) in Safari from javascript

i'm implementing an on-screen Keyboard for a javascript-Application. The text should appear in a textarea-Element. I've no problem creating text-events but feel unable to create non-text events such as the Backspace. Here is some sample code: <html> <head> <title>Test Textarea Events</title> <script type="text/javascript"> function log(text) { var elem = document.getElementById("log"); if (elem) { elem.innerHTML += "<br/>" + text; } } function logEvent(e) {...Read more

onmouseout JavaScript event being called when I move the cursor over an element without going out of the element

I have an image in a page and in the "onmouseover" event of that image I will call a JavaScript function to show a tooltip and in the "onmouseout" of the image, I will call a method to hide the tooltip. Now I found that when I place the cursor on the image, it's calling the method to show the tooltip div.And if I move the mouse within the image, it's calling the onmouseout event (even if I am not out of the image). How can I stop this? I want onmouseout to be called when the cursor is out of the image. Any thoughts?Here is how I call it: <im...Read more

javascript events - Mootools - detecting an instance of a css class

I have a website that I have added some basic Mootools animation to. Here is the page of the website i have a question on: will notice that when you mouse over the large images, they fade and a magnifying glass tweens down. Here is the Mootools class called "Magnify" I made for this:var Magnify = new Class({Implements : [Options, Events],options : { },initialize : function (item, image, options){ this.setOptions(options); this.div =; this.img = $$(image); this...Read more

javascript events - Appcelerator Titanium tableView

I have a problem with tableView, specifically when I use a valid url as data for leftImage.It works like a charm if I use a local file, but not with any valid URL.Can anyone help me with this and tell me what I am doing wrong, and how it could be fixed so that I can display a jpg from a remote server?Thanks in advance ablazso@gmail.comP.S. Below is the related Titanium code. I am using Titanium Mobile 1.7.2 in Titanium Studio //... var thisRow = Ti.UI.createTableViewRow({ leftImage: "images/pix_sd_1.jpg", // This works! leftIm...Read more

javascript events - How to make "controls" on a web page that get real time data updates

I am a total newbie to web ASP .NET Core MVC programming and see all these examples of bootstrap and forms with list boxes and simple controls.IN the old days, we used to have active x containers with custom controls that could acquire real time data updates, we used CORBA back then.Is there any functional equivalent in WEB ASP programming? Does an individual HTTP request have to be sent every time an update is wanted? I'd like to have the server objects on the back end decide when it is time to send a change-driven data update.Thank you...Read more

How to make an editable event.keyCode

function keydown(event) { if (event.keyCode == 65) { //key A thing1(); setTimeout(thing1, speed); setTimeout(thing2, speed*2); setTimeout(thing2, speed*2); setTimeout(thing2, speed*2); }Would anybody know how to make the event.keyCode editable? Like instead of saying let's say 65 you can make it editable with a <div id="s-keyn-split" class="setting-row">Split<span class="setting-option"> <div id="keybind-split" class="keybind-setting transitioning clickable">Space<...Read more

javascript events - How to test and implement data layer in Google tag manager for Google analytics

We are using enhanced eCommerce tracking by using data layer,to setup and test it in local environment,we can see page views in analytics but the event and impressions are not triggered i tried use this dataLayer.push({ 'ecommerce': { 'Impression': [ { 'name': '${}' ,'id': '${product.code}' }]}});dataLayer.push({ 'ecommerce': { 'detail': { 'products': [{ 'name': '${}', 'id': '${product.code}', 'variant': '...Read more

CSS3 webkitAnimationEnd event ordering

I'm new to stackoverflow and also relatively new to HTML5 programming. I'm writing something (for Safari, primarily) where the logic is driven by the events which get fired out when webkit animations complete. If I start a number of animations of the same length simultaneously, I need some idea of the order I can expect their completion events to fire. Example:<!DOCTYPE html><html><head> <style> @-webkit-keyframes slideRight { from { left: 0; } to { left: 100px; } } </style></head>&l...Read more

How to add onplay event to all html5 videos that are added dynamically to the page?

I am trying the following code for adding onplay event to all the videos that are added dynamically to my page but it is not working!I tried with jQuery event-delegation but still not working, but I would prefer pure JavaScript solution. document.addEventListener('play', function(e){ console.log("video started"); }) document.addEventListener('play', function(e){ console.log("video started"); })<video width="400" controls> <source src="" type="video/mp4"> Your browser does not...Read more

buttonclick - calling a function from another location on a button click event

i need to call a function by clicking a button.The button is on an aspx page and the function is on a .js page. this is the code i use for my buttonSubmitand this is my functionfunction onBtnSubmitClick() { var startDate = document.getElementById('<%= txtATrendStartDate.ClientID %>').value; var endDate = document.getElementById('<%= txtATrendEndDate.ClientID %>').value; checkDateRange(startDate, endDate); } function checkDateRange(start, end) { // Parse the entries ...Read more

FullCalendar - eventMouseover and eventMouseout Events are not working on custom view

This is my first request here on Stackoverflow so please be patient if I don't meet all the requirements ;)I developed a calendar with FullCalendar and I use the standard-view and a custom view which displays my events in a list-like-style.Everything is shown up properly but the default eventMouseover and eventMouseout-handler are not called for events on my custom view :(Is there any special requirements I have to do in the renderEvents-Function? The only thing I do there is to build the event-table html.Or do I miss some options? I haven't fo...Read more

javascript events - jq tounch id attar occuring twice

$('#news_details').bind('pageAnimationEnd', function (e, info) { // get the id of the calling href //alert('we are here'); var id = $(this).data('referrer')[0].id; //alert(id); $.get('http://localhost/school_app/admin/json/news_pagination.php?id=' + id, function (data) { // do something with the data //alert(data); $('#detail_news').append(data); //alert('we are here'); }); }); I am geting this id and passing it to the #news_details page,i...Read more