Menu
Newbedev LogoNEWBEDEV Python Javascript Linux Cheat sheet
Newbedev LogoNEWBEDEV
  • Python 1
  • Javascript
  • Linux
  • Cheat sheet
  • Contact

set button to new page html code example

Example 1: add link behind a button in html

Click to copy
<!DOCTYPE html>
<html>
   <head>
      <title>Title of the document</title>
   </head>
   <body>
      <form>
         <input type="button" onclick="window.location.href = 'https://www.w3docs.com';" value="w3docs"/>
      </form>
   </body>
</html>

Example 2: html button click url

Click to copy
# Wrap whole button in a 'a' tag.
 <a href="https://google.com" class="button"><button class="pixel">Button text</button></a>

Tags:

Html Example

Related

laravel curent user id code example remove extra spaces from string python regex code example mysql datetime in select code example python all files size in directory code example gcc cpp compile code example bootstrap datepicker bootstrap 3 default value code example form select option php code example regex functions javascript code example function substring does work in nodejs code example reverse bits java code example text-transform: capitalize in bootstrape code example asp.net core mvc connection string trusted connection code example

Recent Posts

Pandas how to find column contains a certain value Recommended way to install multiple Python versions on Ubuntu 20.04 Build super fast web scraper with Python x100 than BeautifulSoup How to convert a SQL query result to a Pandas DataFrame in Python How to write a Pandas DataFrame to a .csv file in Python
© 2021 newbedevPrivacy Policy