Answers for "javascript onclick call function with parameters"

3

javascript onclick parameters

<button onclick="myfunctionName('John')">Click</button>

<script type="text/javascript">
	function myfunctionName(String){
		alert(String);
	}
</script>
<!-- Will Show an Alert Box Saying "John" -->
Posted by: Guest on May-02-2021

Code answers related to "javascript onclick call function with parameters"

Browse Popular Code Answers by Language