Solved

Button not taking me to the href

Posted on 2016-10-18
3
25 Views
Last Modified: 2016-10-18
<button type="button" class="btn btn-info btn-lg pull-center" href= "page2.php">2. By s EDI Files<br>(through web )</button>

Open in new window


I have this button but its not taking me to page2.php, im not sure why
0
Comment
Question by:Jasmine Ikhreishi
  • 2
3 Comments
 
LVL 51

Expert Comment

by:Julian Hansen
Comment Utility
Buttons are not links - rather use a link and style it as a button i.e

<a class="btn btn-info btn-lg pull-center" href= "page2.php">2. By s EDI Files<br>(through web )</a>

Open in new window

0
 
LVL 22

Accepted Solution

by:
Ferruccio Accalai earned 500 total points
Comment Utility
or use onclick
<button type="button" class="btn btn-info btn-lg pull-center" onclick="window.location.href='page2.php'">2. By s EDI Files<br>(through web )</button> 

Open in new window

0
 
LVL 51

Expert Comment

by:Julian Hansen
Comment Utility
Why define an onlick for a button when a <a> looks exactly the same and does the same thing by default?
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

Nothing in an HTTP request can be trusted, including HTTP headers and form data.  A form token is a tool that can be used to guard against request forgeries (CSRF).  This article shows an improved approach to form tokens, making it more difficult to…
This article discusses how to create an extensible mechanism for linked drop downs.
Explain concepts important to validation of email addresses with regular expressions. Applies to most languages/tools that uses regular expressions. Consider email address RFCs: Look at HTML5 form input element (with type=email) regex pattern: T…
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

6 Experts available now in Live!

Get 1:1 Help Now