Arrie
Arrie

Reputation: 1337

Dreamweaver on click

Hey guys below is the code i have in html in Dreamweaver cs 6 for my button just to go from index_home.html(witch is a login) to the index_main.html page there is no logic behind this i just need the onclick/href= to work but for some reason mine doesn't! using dreamweaver cs 6, html 5.

im not a newcomer to html , just dreamweaver : here is code!

    <div id="Buttons">
<br/>
  <form method="post" name="buttons" id="buttons">
    <button name="Login" id="Login" href="index_main.html">LogIn</button>
    <button name="Register" id="Register" >Register</button>
  </form>
</div>

just the login that has the href in it so long, dont wanna go on until i got this basic stuff working :) any ideas will be appreciated

Upvotes: 0

Views: 986

Answers (1)

Andy
Andy

Reputation: 14575

You can't have a href on a button.

Either:

  • Make it into an a tag with a href
  • Do an onclick to redirect
  • Make the button a submit button type="submit", and set the forms action to the page you want to be sent to.

Upvotes: 2

Related Questions