X-Cart: shopping cart software

X-Cart forums (https://forum.x-cart.com/index.php)
-   Dev Questions (https://forum.x-cart.com/forumdisplay.php?f=20)
-   -   Manufacturers in a dropdown (https://forum.x-cart.com/showthread.php?t=10416)

mffowler 11-16-2004 07:57 PM

Manufacturers in a dropdown
 
In an endless effort to make X-Cart less obsessed with column menus (new feature=new column menu), I put the manufacturers in a dropdown selector. Just a cut and paste of codes, but maybe someone can use the solution. The "if" statement is in there, so manufacturers should be enabled or disabled in "Modules" respectively.

Be sure to keep the "absolute" URL in value, as the links won't work correctly when in the html catalog. I'm using it in the head.tpl inside one of the tables <TD> tag sets.

Code:

{if $manufacturers_menu ne ''}
        <form name="ManufacturerMenu">

        <select onChange="location=this.options[this.selectedIndex].value;" style="font-size:11px; color:#333333; width:140px;">
          <option>Shop By Manufacturer</option><option value="http://yourdomain.com/store/home.php">---------------------------</option>

{section name=mid loop=$manufacturers_menu}
<option value="http://yourdomain.com/store/manufacturers.php?manufacturerid={$manufacturers_menu[mid].manufacturerid}">{$manufacturers_menu[mid].manufacturer}</option>
{/section}

        </select>

        </form>
{else}

{/if}


- Mike

EnriqueHavoc 11-16-2004 09:41 PM

Thanks... how would you make it so "Shop by Manufacturer" and "------------------" dont bring up broken links if selected?

mffowler 11-17-2004 03:35 AM

I fixed that - correct code above now. As the "----" is an <option>, just add the absolute home page of: http://yourdomain.com/store/home.php and it will return the user to the main home page of the site.

I quite like the dropdown for manufacturers ...

- Mike

wpd911 11-23-2004 07:28 PM

Is there a way to get the dropdown to list ALL the manufacturers? It seems to stop at 10.

PhilJ 11-24-2004 12:40 AM

this might help you
http://forum.x-cart.com/viewtopic.php?t=7167&start=15

brightway 01-25-2005 01:00 PM

Hi.

I am wanting to add the drop down menu into the
modules/Manufacturers/menu_manufacturers.tpl file.

Removing the standard list of manufacturers and having the drop down instead..but still having the standard xcart manufactures heading.
Where would I stick this code, in this .tpl file?

Thanks.

Danielle 02-14-2005 02:34 PM

Yeah I would like this too, I found another mod that does edit the code in the menu_manufacturers.tpl file, but it still made a new area. I would like the dropdown to be under the existing Manufacturer heading and then for the existing list to be gone.

Anyone know how to make this work???

Thanks!


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

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