Search
 
SCRIPT & CODE EXAMPLE
 

JAVASCRIPT

onclick a hyperlink and display the id of clicked hyperlink js

<a href="" type="button" onclick="myFunction(this.id)" id="One">Click</a>

<script>
  function myFunction(a){
		alert(a);
	}
</script>
Comment

PREVIOUS NEXT
Code Example
Javascript :: toggling individual item using map in react 
Javascript :: counting number of times a string is in another string 
Javascript :: buiding react project 
Javascript :: wordpress how to read jquery 
Javascript :: zustand stores manage loading state 
Javascript :: svelte function at interval 
Javascript :: desync resolver 
Javascript :: jquery on mouseover and mouseout 
Javascript :: devlop 
Javascript :: terraform for loop json 
Javascript :: function solution(n) { } 
Javascript :: image gallery functions 
Javascript :: negative index javascript 
Javascript :: javascript For some reason my content within an array is not printing out to the screen 
Javascript :: angularjs GetVideos API, Cant get the key parameter inside the array 
Javascript :: AngularJS get ETag header from $http.put request 
Javascript :: Algolia backend search with Algolia Search Helper library for Angular.js 
Javascript :: How to hide div based on select the dropdown in angular js 
Javascript :: Pass JSON array to function in React as props and then count items in area 
Javascript :: Undefined value document.getElementById 
Javascript :: splunk : json spath extract 
Javascript :: Special Chars like DOTS in Express.js route 
Javascript :: ansel array sort 
Javascript :: online jquery converter 
Javascript :: angular 13 deploy on tomcat 9 
Javascript :: vimscript replace function 
Javascript :: module imports renaming 
Javascript :: Set Up Model In MongoDB 
Javascript :: blob to wav javascript 
Javascript :: true type of javascript 
ADD CONTENT
Topic
Content
Source link
Name
7+6 =