• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 101
  • Last Modified:

IE Does not Open Link

Hi Experts,

I have a very basic script as follows:
 <!DOCTYPE html>
<html lang="en">

 <head>
	<meta charset="utf-8">
        <title>RS @ APD</title>
	<link rel="stylesheet" href="https://192.168.1.202/CSS_Reservations/styles/main.css">
        
        
        <link rel="stylesheet" href="https://192.168.1.202/CSS_Reservations/styles/">
            
</head>


    <body >

        <h1>RS @ APD</h1><br>
        <h2>Temporary Dispatch Page</h2>
        
        <!--Content Start-->

    <!--content-->
    <a href="../addedit/"> <input type="button" value="Add/Edit" class="buttons"> </a>
    <br><br>
    
    <a href="../login/?action=logout"> <input type="button" value="Logout" class="buttons"> </a>
    <br><br>
         
<!--Place where appropriate-->
        <!--Info Start-->
        <div id="info">
            <img src="https://192.168.1.202/CSS_Reservations/images/info.gif">
            <p> Please make your selection... </p>
        </div>
    <!--Info Finish-->

 
    
        <!--Content Finish-->

    </body>
 
 </html>

Open in new window


The buttons work in all browsers except the very special IE. Any idea why
0
APD Toronto
Asked:
APD Toronto
  • 5
1 Solution
 
F PCommented:
You can't have a button tag/element inside an a (anchor) tag/element.

Reference:
http://www.w3.org/TR/html-markup/button.button.html#button.button

The interactive element button must not appear as a descendant of the a element.
0
 
F PCommented:
.. The fact that it works in other browsers are from developers being nice and allowing your mistake to work.
0
 
F PCommented:
If you want it to work, change the code to this:

<input type="button" value="Add/Edit" class="buttons" onClick="JavaScript:location.href='../addedit/';">
<input type="button" value="Logout" class="buttons" onClick="JavaScript:location.href='../login/?action=logout';">

Open in new window

0
Cloud Class® Course: CompTIA Cloud+

The CompTIA Cloud+ Basic training course will teach you about cloud concepts and models, data storage, networking, and network infrastructure.

 
APD TorontoAuthor Commented:
This make sense, but the funny thing is that this also worked on IE 2 weeks ago, but not anymore.
0
 
F PCommented:
IE and Microsoft are the "we walk our own path" and try to be leaders.. instead of following standards and conventions. You never know with them what will happen.
0
 
F PCommented:
... lol, I just remembered a saying I often use. Everything works until it doesn't.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Get expert help—faster!

Need expert help—fast? Use the Help Bell for personalized assistance getting answers to your important questions.

  • 5
Tackle projects and never again get stuck behind a technical roadblock.
Join Now