Jump to content
  • Checkout
  • Login
  • Get in touch


The e-commerce.

Category Listing


Recommended Posts

Off the main index page, when you click on a Category & pull up a list of everything in that category -- that's what I'm working on.


The current code allows you to list one product per line, and one item per column. I would like to change this so that the picture on the far left is in a smaller <td> and in the next column I can list several things -- the name, some product info, etc.


But the coding does not seem to allow for this. I don't fully understand the PHP used here, & I can't find any documentation for it on the PHP site.


Under catalog/includes/modules/product_listing.php, on about line 90 in the unmodified code, you see:


switch ($column_list[$col]) {
         case 'PRODUCT_LIST_MODEL':
           $lc_align = '';
           $lc_text = ' ' . $listing['products_model'] . ' ';


So far it hasn't allowed me to add to the $lc_text or have more than one entry for $lc_text. Can someone direct me to information about this coding, and how to edit it?


Or is there a contribution for changing this area of the site? I'm not sure how to even search for this, as my current two days of searching the forums, contributions, and documentation has not gotten me anywhere.


I want customers to be able to click on a category & get a better overview of each product than just a picture, name, & price. There is one more piece of information I would like to add (and change the layout a bit). Just being able to do that would help my customers navigate & find products they like.





Link to comment
Share on other sites

I figured out why I hadn't been able to make the changes here & successfully made them.


In this file there are if statements for each scenario -- for when things are called by manufacturer or by category (I don't use the manufacturer part on my site) -- I wasn't making changes to the $lc_text for the correct IF statements. I went back & made changes to both scenarios (in case I ever use the coding for manufacturer).


I decided to do what I usually do -- use the OSC original coding as much as possible (because I have found that you never know what other function you're going to be messing with!). And figured out how to make it work for me.


On this particular problem I discovered that sometimes it is quite helpful to physically print out the code & mark on it with a pen what each section is doing until -- aha! duh! -- you figure out what you're missing.




Link to comment
Share on other sites


This topic is now archived and is closed to further replies.

  • Create New...