Jump to content

IE7 madness


simulastral

Recommended Posts

Turns out the search works every time if you use the submit button to submit, but not if you hit the enter key.  Who would have thunk it?  Is there a solution to this problem so that the enter key works everytime?

 

A snippet of my previously posted code:

 

  if (isset($_POST['search']))

  {

  include('db_connect.php');

  include('sec_script.php');

  $product = escape_data($_POST['product']);

  $query = "SELECT id, productname, other, address FROM products WHERE MATCH (productname) AGAINST ('$product') ORDER BY productname";

  $result = @mysql_query ($query);

  while ($row = mysql_fetch_array($result, MYSQL_ASSOC)){

 

AND THE FORM:

 

<p style="margin-bottom:0px;">Product Search: </p><form action="search.php" method="post"><input name="product" type="text" /> <input type="submit" name="submit" value="search" /></form>

 

Link to comment
Share on other sites

you could use javascript BUT users will soon learn that the submit button has to be hit so I would not bother putting in extra work that is unneccessary and may play up when you are in a textarea....

 

just live with it - it doesn't hurt.

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.