onclick location href | Open HTML pages/website on a button click

If you want to open these HTML pages on a button click use onclick location href. onclick Attribute Input tag onclick location href Example HTML code: Output: OR Button html href Do comment if you have any doubts and suggestions on this HTML/JS tutoiral. RohitDegree in Computer Science and Engineer: App Developer and has multiple Read More…


JavaScript onclick href | Example code

Use onclick location href to call website or page in HTML. It can use mostly tags available in HTML. JavaScript onclick href Example HTML example code: Linking pages using buttons click event In tag <a> In Function Output: Do comment if you have any doubts and suggestions on this JS href tutorial. RohitDegree in Computer Read More…



HTML a href call JavaScript function | Example code

You can use href or on click method to call a JavaScript function from HTML elements. A href call function : href HTML a href call JavaScript function example Simple addition function will call on clicking the link, where function will call from href attribute. In the example we are doing call JavaScript function from Read More…


Open multiple tabs with one link | JavaScript code

For example, we want to open 2 URLs (http://google.com and http://yahoo.com) in a different tab with one link click. You can do it in 2 ways defining in a tag or use JavaScript. But in both cased you have to use a window.open method. Open multiple tabs with one link Examples Here is a basic Read More…



Multiple href in one link example | JS Code

You can’t Multiple href in one link HTML alone, because there’s only a single href attribute. Use the window.open() method in JavaScript: Multiple href in one link In JavaScript Complete example code: In Anchor tag In Script In function call window.open(‘url’). Example code create a multiple link for a single <a href> tag. Output: Do Read More…