vote-for-pedro Posted August 17, 2007 Share Posted August 17, 2007 the code below is for a search box with an image as the submit button (button_quick_find.gif). how can i change it so instead of an image, the word search is the submit link? <?php $hide = tep_hide_session_id(); echo '<form name="quick_find" method="get" action="' . tep_href_link (FILENAME_ADVANCED_SEARCH_RESULT, '', 'NONSSL', false) . '">'; echo $hide . '<input type="text" name="keywords" size="15" maxlength="30" value="' . htmlspecialchars(StripSlashes(@$HTTP_GET_VARS["keywords"])) . '"> ' . tep_image_submit('button_quick_find.gif', BOX_HEADING_SEARCH); echo '</form>'; ?> Link to comment https://forums.phpfreaks.com/topic/65439-simple-image-link-problem/ Share on other sites More sharing options...
flappy_warbucks Posted August 17, 2007 Share Posted August 17, 2007 javascript? you could do <input type="image" src="bla bla bla" onClick="javascript:document.myform.submit()"> Just an idea? Link to comment https://forums.phpfreaks.com/topic/65439-simple-image-link-problem/#findComment-326853 Share on other sites More sharing options...
l3asturd Posted August 17, 2007 Share Posted August 17, 2007 why not use the button type? ie: <input type=\"button\" name=\"Search\" etc etc Link to comment https://forums.phpfreaks.com/topic/65439-simple-image-link-problem/#findComment-326856 Share on other sites More sharing options...
HuggieBear Posted August 17, 2007 Share Posted August 17, 2007 why not use the button type? ie: <input type=\"button\" name=\"Search\" etc etc That's the way I'd go, and use CSS to style it. Regards Huggie Link to comment https://forums.phpfreaks.com/topic/65439-simple-image-link-problem/#findComment-326860 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.