View Single Post
  #5  
Old 11-08-2007, 02:01 PM
 
gravel gravel is offline
 

Senior Member
  
Join Date: Mar 2004
Posts: 156
 

Default Re: Cursor starting in Search form?

I found something that works in both FF and IE, and no "error on page" msgs. It sets an ID for both the search form and the text box. For example:

In search.tpl:

Code:
<form method="get" action="search.php" name="search" id="formid"> ... <input type="text" name="whatever" id="textboxid" value="{$searchstring|escape:'html'}" onFocus="this.value=''" tabindex="1" /> ... </form>
In home.tpl:

Code:
<body onload="document.forms.formid.textboxid.focus()">
__________________
X-Cart version 4.0.17
X-Cart version 4.0.18
Web servers = Apache
OS = Linux
Reply With Quote