Follow us on Twitter X-Cart on Facebook Wiki
Shopping cart software Solutions for online shops and malls
 

Modify Layout of Manufacturers Page

 
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design
 
Thread Tools Search this Thread
  #1  
Old 12-05-2012, 03:36 PM
 
tartaglia tartaglia is offline
 

X-Adept
  
Join Date: May 2006
Location: Dallas, TX
Posts: 575
 

Default Modify Layout of Manufacturers Page

I want to modify the layout of the Manufacturers page. The default layout is an unordered list of just the manufacturer names. The relevant default code inside /common_files/modules/Manufacturers/customer_manufacturers_list.tpl is...

Code:
<ul class="manufacturers-list list-item"> {foreach from=$manufacturers item=v} <li><a href="manufacturers.php?manufacturerid={$v.manufacturerid|amp}">{$v.manufacturer|escape}</a></li> {/foreach} </ul>

I stole some code from the customer_manufacturer_products.tpl file in order to get the manufacturer logos to show. Code now looks like this...

Code:
<ul class="manufacturers-list list-item"> {foreach from=$manufacturers item=v} <li> <a href="manufacturers.php?manufacturerid={$v.manufacturerid|amp}"> <img src="{if $v.image_url ne ''}{$v.image_url|amp}{else}{$xcart_web_dir}/image.php?id={$v.manufacturerid}&amp;type=M{/if}" alt="{$v.manufacturer|escape}"{if $v.image_x} width="{$v.image_x}"{/if}{if $v.image_y} height="{$v.image_y}"{/if} /> {$v.manufacturer|escape} </a> </li> {/foreach} </ul>

What I REALLY want is to have these logos + text links for each manufacturer to be in a table format (rows and columns) so you don't have to scroll down so far to see them all. I would be willing to hardcode the number of columns fi the rows were dependant on the number of manufacturers defined.

Can anyone help with this formatting? Please.
__________________
David Coggan
Carolyn Nussbaum Music Company
X-Cart v4.5.4 Gold +
LiteCommerce v2.2.41 (previous 6 years)
Reply With Quote
  #2  
Old 12-05-2012, 03:40 PM
 
tartaglia tartaglia is offline
 

X-Adept
  
Join Date: May 2006
Location: Dallas, TX
Posts: 575
 

Default Re: Modify Layout of Manufacturers Page

Here is a screen shot of where I am at versus where I would like to be.
Attached Thumbnails
Click image for larger version

Name:	Manufacturers_page.jpg
Views:	119
Size:	44.2 KB
ID:	3296  Click image for larger version

Name:	Manufacturers_page_preferred.jpg
Views:	117
Size:	24.7 KB
ID:	3297  
__________________
David Coggan
Carolyn Nussbaum Music Company
X-Cart v4.5.4 Gold +
LiteCommerce v2.2.41 (previous 6 years)
Reply With Quote
  #3  
Old 12-05-2012, 07:52 PM
  totaltec's Avatar 
totaltec totaltec is offline
 

X-Guru
  
Join Date: Jan 2007
Location: Louisville, KY USA
Posts: 5,823
 

Default Re: Modify Layout of Manufacturers Page

Once again I will ask for a link if possible. This is a css issue of course, and working right on the page makes it much easier to suggest a solution, rather than guessing.

Try:
Code:
.manufacturers-list ul li { float: left; }
Also experiment with "display: inline-block;" instead of float.
__________________
Mike White - Now Accepting new clients and projects! Work with the best, get a US based development team for just $125 an hour. Call 1-502-773-6454, email mike at babymonkeystudios.com, or skype b8bym0nkey

XcartGuru
X-cart Tutorials | X-cart 5 Tutorials

Check out the responsive template for X-cart.
Reply With Quote
  #4  
Old 12-05-2012, 09:27 PM
  totaltec's Avatar 
totaltec totaltec is offline
 

X-Guru
  
Join Date: Jan 2007
Location: Louisville, KY USA
Posts: 5,823
 

Default Re: Modify Layout of Manufacturers Page

I sent you a message.
__________________
Mike White - Now Accepting new clients and projects! Work with the best, get a US based development team for just $125 an hour. Call 1-502-773-6454, email mike at babymonkeystudios.com, or skype b8bym0nkey

XcartGuru
X-cart Tutorials | X-cart 5 Tutorials

Check out the responsive template for X-cart.
Reply With Quote
  #5  
Old 12-05-2012, 11:46 PM
  ADDISON's Avatar 
ADDISON ADDISON is offline
 

X-Man
  
Join Date: Jan 2008
Posts: 2,613
 

Default Re: Modify Layout of Manufacturers Page

If I am right you could use list2matrix smarty function already in XC
__________________
X-Cart Next: Business 5.2 (learning and testing)
X-Cart Classic: Gold and Gold Plus 4.7
Lots of Modules and Customizations
OS in use: Red Hat Enterprise, Fedora, CentOS, Debian, Ubuntu, Linux Mint, Kali Linux
Ideas for Server configuration (basicaly): Nginx/Pound (reverse proxy), Apache/Nginx (webserver), Squid/Varnish (cache server), HHVM or (PHP-FPM + PHP 5.6 + opcache), MariaDB/Percona MySQL Server, Redis (storing sessions)

You can catch my ideas here: http://ideas.x-cart.com
Reply With Quote

The following user thanks ADDISON for this useful post:
totaltec (12-05-2012)
  #6  
Old 12-05-2012, 11:58 PM
  totaltec's Avatar 
totaltec totaltec is offline
 

X-Guru
  
Join Date: Jan 2007
Location: Louisville, KY USA
Posts: 5,823
 

Default Re: Modify Layout of Manufacturers Page

We were able to do it with some simple CSS styles, but list 2 matrix would work fine as well.

I also like to use counters on a foreach loop, counting the iterations and spitting out a break line of some kind when it reaches the nth one.
__________________
Mike White - Now Accepting new clients and projects! Work with the best, get a US based development team for just $125 an hour. Call 1-502-773-6454, email mike at babymonkeystudios.com, or skype b8bym0nkey

XcartGuru
X-cart Tutorials | X-cart 5 Tutorials

Check out the responsive template for X-cart.
Reply With Quote
  #7  
Old 12-06-2012, 01:49 AM
 
anandat anandat is offline
 

X-Adept
  
Join Date: Jan 2004
Posts: 914
 

Default Re: Modify Layout of Manufacturers Page

checkout this module http://www.websitecm.com/x-cart-mods/xcart-manufacturers-a-z.html

if you have many manufacturers then above mod will be very useful to you.
__________________
X-Cart: 4.7.7 LIVE
Skin:Ultra by xcartmods.co.uk
X-cart Modules: | ACR, Rich Google Search, Customer Testimonials | Cloud Search, | Websitecm: CDSEO (2.1.9)
---------------
Server: Linux
php: 5.3
mysql: 5.0.89
----------------
Reply With Quote

The following user thanks anandat for this useful post:
totaltec (12-06-2012)
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


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

   

 
X-Cart forums © 2001-2020