X-Cart: shopping cart software

X-Cart forums (https://forum.x-cart.com/index.php)
-   Changing design (https://forum.x-cart.com/forumdisplay.php?f=51)
-   -   Search "Go Button" (https://forum.x-cart.com/showthread.php?t=54532)

daron 07-09-2010 10:35 AM

Search "Go Button"
 
Hello.
Simple thing that I can't seem to figure out.

In my search box area, I want to add a "go" or "arrow" button. Some people have been complaining that they didn't know to hit enter.

My question is where do I add this button. Looking into templates etc, but unsure.
Any code would be helpful as well.
Thanks

X-Cart version 4.2.3

balinor 07-09-2010 10:39 AM

Re: Search "Go Button"
 
The search box should have an arrow by default - what skin are you using? The search template is usually skin1/customer/search.tpl

Moving to Template Editing

daron 07-09-2010 11:11 AM

Re: Search "Go Button"
 
Not sure of the exact name of the skin but coffeysound.com if you want to visit.
I saw the search.tpl under
X Cart Module >
Edit Templates >
Buttons >
search.tpl.

But I am a beginner with Xcart I usually build sites and use a veracart/authoize.net system so this is all new to me.

Any suggestions would be great.
Thanks

ARW VISIONS 07-11-2010 01:13 PM

Re: Search "Go Button"
 
most definitely missing the button. post code of search.tpl

daron 07-12-2010 08:53 AM

Re: Search "Go Button"
 
{include file="buttons/button.tpl" button_title=$lng.lbl_search type="input" href=$href title=$title style=$style}

ARW VISIONS 07-12-2010 09:06 AM

Re: Search "Go Button"
 
that is the entire content of search.tpl?

that is only the code for the button, so how about posting your head.tpl

daron 07-12-2010 09:19 AM

Re: Search "Go Button"
 
Ashely. Thanks for your help. This is the first time I'm working with X Cart so sorry if I seem new - it's because I am at it.

{*
$Id: head.tpl,v 1.65.2.1 2009/09/04 06:35:10 aim Exp $
vim: set ts=2 sw=2 sts=2 et:
*}
<table cellpadding="0" cellspacing="0" width="100%">
<tr>
<td class="HeadLogo"><object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,0,0" width="338" height="83" id="coffeysound_header" align="middle">
<param name="allowScriptAccess" value="sameDomain" />
<param name="movie" value="{$https_location}/files/flash/coffeysound_header.swf" /><param name="loop" value="false" /><param name="menu" value="false" /><param name="quality" value="high" /><param name="wmode" value="transparent" />
<embed src="{$https_location}/files/flash/coffeysound_header.swf" loop="false" menu="false" quality="high" wmode="transparent" width="338" height="83" name="coffeysound_header" align="top" allowScriptAccess="sameDomain" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" />
</object></td>
<td class="HeadRightBox">
{if $usertype eq "C"}
{include file="customer/top_menu.tpl"}
{/if}
</td>
</tr>
</table>
<table cellpadding="0" cellspacing="0" width="100%">
<tr>
<td colspan="2" class="HeadThinLine"><img src="{$ImagesDir}/spacer.gif" class="Spc" alt="" /></td>
</tr>
{if $main ne "fast_lane_checkout"}
<tr>
<td class="HeadLine" height="22">
{if $usertype eq "C"}
{ include file="customer/search.tpl" }
{/if}
</td>
<td class="HeadLine" align="right">
{if ($usertype eq "C" || $usertype eq "B") && $all_languages_cnt gt 1}
<form action="home.php" method="get" name="sl_form">
<input type="hidden" name="redirect" value="{$php_url.url}{if $php_url.query_string ne ''}?{$php_url.query_string|amp}{/if}" />
<table cellpadding="0" cellspacing="0">
<tr>
<td style="padding-right: 5px;" class="TopLabel">{$lng.lbl_select_language}:</td>
<td><select name="sl" onchange="javascript: this.form.submit();">
{section name=ai loop=$all_languages}
<option value="{$all_languages[ai].code}"{if $store_language eq $all_languages[ai].code} selected="selected"{/if}>{$all_languages[ai].language}</option>
{/section}
</select></td>
</tr>
</table>
</form>
{else}
&nbsp;
{/if}
</td>
</tr>
{else}
{* Fast Lane Checkout page *}
<tr>
<td colspan="2" class="HeadLine">
<form action="{$xcart_web_dir}/include/login.php" method="post" name="toploginform">
<input type="hidden" name="mode" value="logout" />
<input type="hidden" name="redirect" value="{$redirect|amp}" />
<table cellpadding="0" cellspacing="0" width="100%">
<tr>
<td class="FLCAuthPreBox">
{if $active_modules.SnS_connector and $sns_collector_path_url ne '' && $config.SnS_connector.sns_display_button eq 'Y'}
<img src="{$ImagesDir}/rarrow.gif" alt="" valign="middle" /><b>{include file="modules/SnS_connector/button.tpl" text_link="Y"}</b>
{else}
<img src="{$ImagesDir}/spacer.gif" class="Spc" alt="" />
{/if}
</td>
{if $login ne ""}
<td align="right" nowrap="nowrap"><b>{if $userinfo.firstname or $userinfo.lastname}{$userinfo.firstname} {$userinfo.lastname}{else}{$login}{/if}</b> {$lng.txt_logged_in}</td>
<td class="FLCAuthBox">
{if $js_enabled}
{include file="buttons/button.tpl" button_title=$lng.lbl_logoff href="javascript:document.toploginform.submit();" js_to_href="Y"}
{else}
{include file="buttons/button.tpl" button_title=$lng.lbl_logoff href="javascript:document.toploginform.submit();" js_to_href="Y" image_menu=true type="input"}
{/if}
</td>
{/if}
</tr>
</table>
</form>
</td>
</tr>
{/if}
<tr>
<td colspan="2" class="HeadThinLine"><img src="{$ImagesDir}/spacer.gif" class="Spc" alt="" /></td>
</tr>
{******** Remove this line to display how much products there are online ****
<tr>
{insert name="productsonline" assign="_productsonline"}
<td colspan="2" class="NumberOfArticles" align="right">
{if $config.Appearance.show_in_stock eq "Y"}
{insert name="itemsonline" assign="_itemsonline"}
{$lng.lbl_products_and_items_online|substitute:"X" :$_productsonline:"Y":$_itemsonline}
{else}
{$lng.lbl_products_online|substitute:"X":$_product sonline}
{/if}
&nbsp;
</td>
</tr>
**** Remove this line to display how much products there are online ********}
{if $main ne "fast_lane_checkout"}
<tr>
<td colspan="2" valign="middle" height="32">
<table cellspacing="0" cellpadding="0" width="100%">
<tr>
<td class="HeadTopPad"><img src="{$ImagesDir}/spacer.gif" alt="" /></td>
{if (($main eq 'catalog' && $cat ne '') || $main eq 'product' || ($main eq 'comparison' && $mode eq 'compare_table') || ($main eq 'choosing' && $smarty.get.mode eq 'choose')) && $config.Appearance.enabled_printable_version eq 'Y'}
<td class="PrintableRow" align="right">{include file="printable.tpl"}</td>
{/if}
</tr>
</table>
</td>
</tr>
{else}
{* Fast Lane Checkout page *}
<tr>
<td colspan="2" class="FLCTopPad"><img src="{$ImagesDir}/spacer.gif" alt="" /></td>
</tr>
{/if}
</table>

ARW VISIONS 07-12-2010 09:26 AM

Re: Search "Go Button"
 
oops... your search is actually in your left-bar.

look in home.tpl and find #left-bar

post that section. Sry for the confusion.

Ash

daron 07-12-2010 10:23 AM

Re: Search "Go Button"
 
No confusion - just very appreciative of the help.

<div id="left-bar">
{if $usertype eq "C"}
{ include file="customer/search.tpl" }
{/if}
{if $categories && ($active_modules.Fancy_Categories || $config.General.root_categories eq "Y" || $subcategories)}
{include file="customer/categories.tpl" }
{/if}
{if $active_modules.Bestsellers}
{include file="modules/Bestsellers/menu_bestsellers.tpl" }
{/if}
{if $active_modules.Manufacturers ne "" and $config.Manufacturers.manufacturers_menu eq "Y"}
{include file="modules/Manufacturers/menu_manufacturers.tpl" }
{/if}
{include file="customer/special.tpl"}
{if $active_modules.Survey && $menu_surveys}
{foreach from=$menu_surveys item=menu_survey}
{include file="modules/Survey/menu_survey.tpl"}
{/foreach}
{/if}
{include file="resources.tpl" }
{* {include file="customer/help/menu.tpl"} *}
</div>
<div

ARW VISIONS 07-12-2010 10:31 AM

Re: Search "Go Button"
 
so are you sure you have looked in skin1/customer/search.tpl??

Ash

daron 07-12-2010 10:38 AM

Re: Search "Go Button"
 
This may be of better use.

{* $Id: search.tpl,v 1.9 2005/11/17 06:55:37 max Exp $ *}
<div class="menu-dialog menu-special">
<div class="title-bar valign-middle">
<img src="skin1/images/spacer.gif" alt="Search" />Search
</div>
<div class="content">
<form method="post" action="search.php" name="productsearchform">
<input type="hidden" name="simple_search" value="Y" />
<input type="hidden" name="mode" value="search" />
<input type="hidden" name="posted_data[by_title]" value="Y" />
<input type="hidden" name="posted_data[by_shortdescr]" value="Y" />
<input type="hidden" name="posted_data[by_fulldescr]" value="Y" />
<table cellpadding="0" cellspacing="0">
<tr>
{* <tr class="TopLabel" style="padding-left: 20px; padding-right: 5px;"><a href="javascript: document.productsearchform.submit();">{$lng.lbl_se arch}:</a></tr> *}
<td valign="middle"><input type="text" name="posted_data[substring]" size="16" value="{$search_prefilled.substring|escape}" /></td>
</tr><tr valign="middle" style="padding-left: 5px; padding-right: 20px;">{* {include file="buttons/search_head.tpl"} *}</tr>
{*<td><a href="search.php"><u>{$lng.lbl_advanced_search}</u></a></td> *}
</tr>
</table>
</form>
</div>
</div>

cflsystems 07-12-2010 10:48 AM

Re: Search "Go Button"
 
The search button is commented out. Uncomment (remove the {* *}) from this line
{* {include file="buttons/search_head.tpl"} *}

ARW VISIONS 07-12-2010 10:49 AM

Re: Search "Go Button"
 
this

{* {include file="buttons/search_head.tpl"} *}

should be

{include file="buttons/search_head.tpl"}



just un-comment button

daron 07-12-2010 11:00 AM

Re: Search "Go Button"
 
You're awesome, Ashely Thank you. Now I just need to figure how to align it correctly.

ARW VISIONS 07-12-2010 11:20 AM

Re: Search "Go Button"
 
make sure to hit the little thanks button, so I can win my visa gift card ;)

seriously your welcome

ARW VISIONS 07-12-2010 11:51 AM

Re: Search "Go Button"
 
tis whole thing

<tr>
{* <tr class="TopLabel" style="padding-left: 20px; padding-right: 5px;"><a href="javascript: document.productsearchform.submit();">{$lng.lbl_se arch}:</a></tr> *}
<td valign="middle"><input type="text" name="posted_data[substring]" size="16" value="{$search_prefilled.substring|escape}" /></td>
</tr><tr valign="middle" style="padding-left: 5px; padding-right: 20px;">{* {include file="buttons/search_head.tpl"} *}</tr>
{*<td><a href="search.php"><u>{$lng.lbl_advanced_search}</u></a></td> *}
</tr>

shoud read like this

<tr>
{* <tr class="TopLabel" style="padding-left: 20px; padding-right: 5px;"><a href="javascript: document.productsearchform.submit();">{$lng.lbl_se arch}:</a></tr> *}
<td valign="middle"><input type="text" name="posted_data[substring]" size="16" value="{$search_prefilled.substring|escape}" /></td>
<td>{include file="buttons/search_head.tpl"}</td>
</tr>
<tr valign="middle" style="padding-left: 5px; padding-right: 20px;">
<td colspan="2"><a href="search.php"><u>{$lng.lbl_advanced_search}</u></a></td>
</tr>


All times are GMT -8. The time now is 03:01 PM.

Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.