Web Analytics Made Easy -
StatCounter Form issues - CodingForum

Announcement

Collapse
No announcement yet.

Form issues

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Form issues

    I'm using the following code as a form on my site, it works perfectly fine in Firefox/Mozilla but it's not working in Internet Explorer. In Firefox is passes the data along fine and my web page reads the input and does what it needs to. When you click on the image in IE the web page just reloads as if the data wasn't being passed on.

    Code:
    <form action="index.php" method="POST">
    <input type="image" src="stats.jpg" name="page" value="smain" alt="Stats">
    </form>
    Anyone see something wrong with the form?

  • #2
    HTML does not require that the value of <input type="image"> elements
    be sent to the server when one is clicked, so IE and Opera don't. Firefox and other Mozilla browsers do.
    Learn CSS. | SSI | PHP includes | X/HTML Validator | CSS validator | Dynamic Site Solutions
    Java != JavaScript && JScript != JavaScript
    Design/program for Firefox (and/or Opera), apply fixes for IE, not the other way around.

    Comment


    • #3
      Originally posted by Kravvitz View Post
      HTML does not require that the value of <input type="image"> elements
      be sent to the server when one is clicked, so IE and Opera don't. Firefox and other Mozilla browsers do.
      Well that sucks, guess I have some editing to do now.

      Comment


      • #4
        That code works for me using IE6. If you are testing for the normal form - name="page" and value="smain" results, this is not what you get.

        The $_POST array for this code contains something like the following -

        Key: page_x, Value: 65
        Key: page_y, Value: 43

        $_POST['page_x'] = the x coordinate that was clicked
        $_POST['page_y'] = the y coordinate that was clicked
        Finding out HOW to do something is called research, i.e. keep searching until you find the answer. After you attempt to do something and cannot solve a problem with it yourself, would be when you ask others for help.

        Comment

        Working...
        X