Search
 
SCRIPT & CODE EXAMPLE
 

JAVASCRIPT

onclick on non button

var ele = document.getElementById('x');
if(typeof ele.click == 'function') {
  ele.click()
} else if(typeof ele.onclick == 'function') {
  ele.onclick()
}
Comment

PREVIOUS NEXT
Code Example
Javascript :: javascript get elements that exist in two arrays 
Javascript :: javascript get first 3 characters of string 
Javascript :: print value in jquery 
Javascript :: Scrollbar inside Dropdown of antD component React 
Javascript :: how to reset settimeout in javascript 
Javascript :: get input type js 
Javascript :: error: expected undefined to be a graphql schema. 
Javascript :: get random number node js 
Javascript :: all inputs under div 
Javascript :: iterate through list javascript 
Javascript :: inline confirm box javascript 
Javascript :: view background image in react native 
Javascript :: jquery selector partial class name 
Javascript :: queue en js 
Javascript :: javascript pushstate 
Javascript :: javascript style multiple properties 
Javascript :: array reverse algorithm in js 
Javascript :: expressjs path optional parameters 
Javascript :: Both npm and yarn have created lockfiles for this application, 
Javascript :: js random in range 
Javascript :: add date in javascript 
Javascript :: spread operator merge objects 
Javascript :: angular 404 on refresh 
Javascript :: npm run shell script 
Javascript :: javascript search dictionary by value 
Javascript :: js navigate to anchor 
Javascript :: input field take only number and one comma 
Javascript :: get combinations of two js 
Javascript :: gradlew command not found react native 
Javascript :: today date js 
ADD CONTENT
Topic
Content
Source link
Name
3+3 =