Hi,
I've customized the default search box that appears on every page. For example, I've moved it under the SideBar and changed the border appearance of the input box and added my own search button image. http://fabricwarehouse.com/fabric/
That was customizable in page.tpl.php and css files. No problem there. :>)

Now, I can't find the code that allows me to do the same for the /search/node box. Or maybe, I don't know how to modify the code in PHP...

I'm using 4.6 with the Civic Labs, Columbus layout.

Here's what I've found in the search.module for php.

>
  $output = ' <div class="search-form">';
  $box = '<div class="container-inline">';
  $box .= form_textfield('', 'keys', $keys, $prompt ? 40 : 20, 255);
  $box .= '<br />';
  $box .= form_submit(t('Search'));
  $box .= '</div>';
  $output .= form_item($prompt, $box);
  $output .= '</div>';

  return form($output, 'post', $action);
<

This is the line of code that I believe needs to be modified: $box .= form_submit(t('Search'));
For example, I'd like to replace the text generated button with my button_search.gif.

My Questions:
Is the Search.module the correct file to modify?
and, How do I modify the php to render a button image instead of a button type?

TIA for any ideas!!

P.S. to further explain, I'm looking for this type of html output:
<input class="form-submit" type="image" src="button_search.gif" width="60" height="23" style="cursor:hand;" id="submit" name="op" alt="Search" />

Instead of the default button style of:
<input class="form-submit" type="submit" id="submit" name="op" value="Search" />

Comments

MaineWebworks’s picture

Does anyone know how to replace input buttons with image buttons in Drupal?