We help IT Professionals succeed at work.

buttons not doing anything when clicked?

finnstone
finnstone asked
on
hoping someone can help me figure out why the button codes arenot working for my site - see below

<input class="btn btn-ghost right" type="button" value="Get early access" href="http://sayhello.xxxxx.co/">

          <input class="btn btn-red" type="button" value="Download" href="http://sayhelloe.xxxxx.co/twitter.xls">
Comment
Watch Question

Most Valuable Expert 2013
Awarded 2012
Commented:
Hi,
what do you expect to happen?
Are you using any kind of Javascript framework on your page?
An input type button does normally not have an attribute of href.

If you want to change the url of the current page, then use this:
<input class="btn btn-ghost right" type="button" value="Get early access" onclick="window.location='http://sayhello.xxxxx.co/';" >

          <input class="btn btn-red" type="button" value="Download" onclick="window.location='http://sayhelloe.xxxxx.co/twitter.xls';">

Open in new window


HTH
Rainer

Author

Commented:
i would like the site to change , without opening a new indow

just this
  <script src="js/vendor/modernizr-2.6.2-respond-1.1.0.min.js"></script>
Most Valuable Expert 2013
Awarded 2012

Commented:
Hi,
then my provided solution should work.

Author

Commented:
that didnt work, while it fixed the error, made button look weird...

also, i actually would like to make it open a small window instead of loading the url in the full window...could you help there?

Author

Commented:
my mistake , fixed it. thx!

but could you also tell me how to open a little window instead of the same window that site is loaded in.