Jump to content
Sign in to follow this  
spooks

Product Listing Enhancements, Thumbnails & Manufacturer Headings

Recommended Posts

Cant say as I don't know where your error is!!

 

Make sure all your forms are correctly closed & not nested

 

If your using a template, remeber they often have many issues due to bad coding.

 

The only other thing I can offer is the url u should see after clicking a link should be like:

 

/index.php?cPath=3_15&sort=0d&max=40

Oh & on that if u have some seo url contrib, some can mess things up too

 

Hmmm, I still can't figure out what goes wrong.

I don't use any templates or a SEO contribution.

 

When I change/click, I indeed see the following address: /index.php?sort=2a&max=40&osCsid=bfc1348d2fbac8a929cf287e5354f5bc.

But it doesn't sort, it goes back to home/index... :angry:

Share this post


Link to post
Share on other sites

Hmmm, I still can't figure out what goes wrong.

I don't use any templates or a SEO contribution.

 

When I change/click, I indeed see the following address: /index.php?sort=2a&max=40&osCsid=bfc1348d2fbac8a929cf287e5354f5bc.

But it doesn't sort, it goes back to home/index... mad.gif

 

 

I would expect that with that url, as its missing the cPath= bit, that says what category your in. Is your site useing cpath instead of cPath?

 

When you click on a category do you see cPath in the url, if not its an issue with your category menu.


Sam

 

Remember, What you think I ment may not be what I thought I ment when I said it.

 

Contributions:

 

Auto Backup your Database, Easy way

 

Multi Images with Fancy Pop-ups, Easy way

 

Products in columns with multi buy etc etc

 

Disable any Category or Product, Easy way

 

Secure & Improve your account pages et al.

Share this post


Link to post
Share on other sites

I would expect that with that url, as its missing the cPath= bit, that says what category your in. Is your site useing cpath instead of cPath?

 

When you click on a category do you see cPath in the url, if not its an issue with your category menu.

 

 

When I click a a category, the url is: index.php/cPath/25?osCsid=10f8e279abce8c8ebaa4888f23642990.

Then I want to sort and it goes to: index.php?sort=3d&osCsid=10f8e279abce8c8ebaa4888f23642990, being in home/index again.

Share this post


Link to post
Share on other sites

Oops... I found it.

 

I said I don't have e SEO contribution, but in admin the default 'search engine friendly' setting stood on 'true'.

Setting it on false, the sorting works!

Share this post


Link to post
Share on other sites

Oops... I found it.

 

I said I don't have e SEO contribution, but in admin the default 'search engine friendly' setting stood on 'true'.

Setting it on false, the sorting works!

 

 

I did wonder about that, in the contrib there are fixes fot some osC bugs, one is related to the seo urls, had u done that I suspect u would'nt have had an issue. ohmy.gif


Sam

 

Remember, What you think I ment may not be what I thought I ment when I said it.

 

Contributions:

 

Auto Backup your Database, Easy way

 

Multi Images with Fancy Pop-ups, Easy way

 

Products in columns with multi buy etc etc

 

Disable any Category or Product, Easy way

 

Secure & Improve your account pages et al.

Share this post


Link to post
Share on other sites

Remove New Product Module

 

What is the best way or code to remove the 'New Products Module' from the product listing page? I want to keep new products running but just not on the listings.

Share this post


Link to post
Share on other sites

Remove New Product Module

 

What is the best way or code to remove the 'New Products Module' from the product listing page? I want to keep new products running but just not on the listings.

 

 

Can you be precise please, are you asking to remove the 'New Products infobox' or the 'New Products Module' used on the home page.


Sam

 

Remember, What you think I ment may not be what I thought I ment when I said it.

 

Contributions:

 

Auto Backup your Database, Easy way

 

Multi Images with Fancy Pop-ups, Easy way

 

Products in columns with multi buy etc etc

 

Disable any Category or Product, Easy way

 

Secure & Improve your account pages et al.

Share this post


Link to post
Share on other sites

Can you be precise please, are you asking to remove the 'New Products infobox' or the 'New Products Module' used on the home page.

 

Sorry,

 

what I am referring to is removing the New Products Images columns and rows and the title bar on the actual listing page. For example, under a category in the middle of the page, it will show the images and title bar for new products. I only want the New Products to be found from in the left column rather than on the center page.

 

Thanks

Share this post


Link to post
Share on other sites

Sorry,

 

what I am referring to is removing the New Products Images columns and rows and the title bar on the actual listing page. For example, under a category in the middle of the page, it will show the images and title bar for new products. I only want the New Products to be found from in the left column rather than on the center page.

 

Thanks

 

 

In the default osC code the 'New Products Module' only appears on the 'home' page, once you are within a categeory only the 'New Products infobox' appears in the left column, if your site behaves otherwise its non-standard, perhaps you have a template?


Sam

 

Remember, What you think I ment may not be what I thought I ment when I said it.

 

Contributions:

 

Auto Backup your Database, Easy way

 

Multi Images with Fancy Pop-ups, Easy way

 

Products in columns with multi buy etc etc

 

Disable any Category or Product, Easy way

 

Secure & Improve your account pages et al.

Share this post


Link to post
Share on other sites

My link

 

sir how can i make the rounder border orange i tried to change css but its still the same?

 

.infoBoxProducts {
 text-align: center;
 font-family: Verdana, Arial, sans-serif;
 font-size: 10px;
border: 1px;
border-style: solid;
border-color: #F57914;
 font-weight: normal;
 background-color:#000000;
 color: #f57914;
margin-bottom:-8px;
-moz-border-radius:15px;
 	-webkit-border-radius:15px;
-khtml-border-radius:15px;
border-radius:15px; 
vertical-align: bottom;
}

 

Sir i have managed to change it now via stylesheet.. but why come it takes two 1 day and some hours to see the changes i have made? is this on my pc or theres something wrong on my codes?

Share this post


Link to post
Share on other sites

In the default osC code the 'New Products Module' only appears on the 'home' page, once you are within a categeory only the 'New Products infobox' appears in the left column, if your site behaves otherwise its non-standard, perhaps you have a template?

 

Yes it is functioning as you mentioned. However, most of my cart is setup to where I don't put images in a parent category but have it rather setup with subcategories with images in there:

 

Main Category

No Product Images But shows New Product Module <- Want to remove here

SubCategory

Images

 

Otherwise if I have images in the main category I don't see New Products as you mentioned. I just don't want it to show for any categories including parent.

Edited by fan4chevy

Share this post


Link to post
Share on other sites

Sir i have managed to change it now via stylesheet.. but why come it takes two 1 day and some hours to see the changes i have made? is this on my pc or theres something wrong on my codes?

 

 

basic operation, style sheets are cached by browser.


Sam

 

Remember, What you think I ment may not be what I thought I ment when I said it.

 

Contributions:

 

Auto Backup your Database, Easy way

 

Multi Images with Fancy Pop-ups, Easy way

 

Products in columns with multi buy etc etc

 

Disable any Category or Product, Easy way

 

Secure & Improve your account pages et al.

Share this post


Link to post
Share on other sites

Main Category

No Product Images But shows New Product Module <- Want to remove here

SubCategory

Images

 

 

 

just remove the line include(DIR_WS_MODULES . FILENAME_NEW_PRODUCTS);


Sam

 

Remember, What you think I ment may not be what I thought I ment when I said it.

 

Contributions:

 

Auto Backup your Database, Easy way

 

Multi Images with Fancy Pop-ups, Easy way

 

Products in columns with multi buy etc etc

 

Disable any Category or Product, Easy way

 

Secure & Improve your account pages et al.

Share this post


Link to post
Share on other sites

just remove the line include(DIR_WS_MODULES . FILENAME_NEW_PRODUCTS);

 

Ok Gotcha! Just to add a note for anyone else wanting to remove the new products. The code Spooks posted is on index.php.

 

Thank you Spooks. Mission accomplished.

Share this post


Link to post
Share on other sites

Hey Sam

 

I'm looking to add a cross sell contribution to my site over the next couple of days to coincide with getting a load of new products (just to create even more work for me!) and i wondered if you could advise whether any have been tested or will work with this contribution?

 

Alternatively do you think you might be able to help me figure out the relevant code changes if i do go ahead with this. I'm looking at the moment at 'X-Sell v2-MS2 - Cross Sell for MS2' avialable here.

 

I thought it best to ask the question now rather than making a load of changes then come looking for help when.

 

Feeedback and support really appreciated as always.

 

Matt

www.orchardstables.co.uk

Share this post


Link to post
Share on other sites

cross sell contribution

 

 

I've never used that, or anything like, the brief description don't really say what it does.

 

If you can say exactly how it works & how that impacts on the listing I would e able to advise as to issues.


Sam

 

Remember, What you think I ment may not be what I thought I ment when I said it.

 

Contributions:

 

Auto Backup your Database, Easy way

 

Multi Images with Fancy Pop-ups, Easy way

 

Products in columns with multi buy etc etc

 

Disable any Category or Product, Easy way

 

Secure & Improve your account pages et al.

Share this post


Link to post
Share on other sites

I've never used that, or anything like, the brief description don't really say what it does.

 

If you can say exactly how it works & how that impacts on the listing I would e able to advise as to issues.

 

Thanks for the reply. I believe it allows me to specify related products in the admin so that on the product pages there is a section at the bottom which shows related products, a little bit like the "customers also bought..." functionality.

 

I dont think it will impact any thing exisitng but i will be keen to get the products displayed as recommended on the product pages in the same format i have across the rest of the site, in rounded corner boxes rather than the stock osc style i believe the contribution sets you up with.

 

I will install on my local test server, havea play with it and then maybe post some of the code that needs to be played with??

 

Thanks Sam

 

Matt

Share this post


Link to post
Share on other sites

Have this contribution installed and am having a couple of problems. /www.paintballwarehouseny.com/index.php

 

1. the new products grid only displays a maximum of 9 products, not enough to fill the grid (12) Where can this be corrected?

 

2. I am having problems with the hovers in Firefox (previously I did with IE but once I fixed that per a post here, it broke Firefox (and Safari) The hover enlargements are appearing UNDER the images to the right of the hover.

 

Any assistance greatly appreciated

 

Sue

Share this post


Link to post
Share on other sites

But still need help on hover problems in Firefox and Safari

 

 

 

 

Firefox issue, strictly speaking its following the rules, as the following images rendered later they appear on top.

 

The best bet is to adjust the horizontal positioning to ensure popup appear directly over the original, unfortunatly the figures vary, depending on images size, popup size & doctype used so my code is only approximate.

 

 

in page-header-inc.htc adjust

margin-left:-<?php echo (int)(IMAGE_TTIP_WIDTH/8) ?>px;

for firefox and

margin-left:-<?php echo (int)(IMAGE_TTIP_WIDTH*0.9) ?>px;

for IE

 

you could replace the calculations with direct values if you wish, as long as you don't intend to change the popup size in admin.


Sam

 

Remember, What you think I ment may not be what I thought I ment when I said it.

 

Contributions:

 

Auto Backup your Database, Easy way

 

Multi Images with Fancy Pop-ups, Easy way

 

Products in columns with multi buy etc etc

 

Disable any Category or Product, Easy way

 

Secure & Improve your account pages et al.

Share this post


Link to post
Share on other sites

Firefox issue, strictly speaking its following the rules, as the following images rendered later they appear on top.

 

The best bet is to adjust the horizontal positioning to ensure popup appear directly over the original, unfortunatly the figures vary, depending on images size, popup size & doctype used so my code is only approximate.

 

 

in page-header-inc.htc adjust

margin-left:-<?php echo (int)(IMAGE_TTIP_WIDTH/8) ?>px;

for firefox and

margin-left:-<?php echo (int)(IMAGE_TTIP_WIDTH*0.9) ?>px;

for IE

 

you could replace the calculations with direct values if you wish, as long as you don't intend to change the popup size in admin.

 

Thanks - I finally got this figured out - and actually both IE and Firefox WERE working the same, it was just that the placement in IE was putting the hover to the left, and on top of the image to the left while Firefox was putting the hover to the right and therefore under that image. When I changed the numbers I reallized when IE put the image to the right the same happened! So it took only a little tweeking once I could see what was happening to adjust both so the hover is centered over the original image and all works great in both browsers. Safari is putting them to the left so this is ok too.

 

Thanks for your patience in helping me sort these things out!

 

Sue

Share this post


Link to post
Share on other sites

Spooks,

 

I have a thought for the contrib. What if the listing page had a different sized image that was called than the product info page?

 

This would allow the image to be increased much larger in the product info page while not effecting the product listing page at all. I did a similar thing for my boxes on the left column where I changed it to look for TinyImage because the original set image was throwing the boxes off.

 

Charles

Share this post


Link to post
Share on other sites

 

 

You can achieve that by simply adding the likes of osCThumb


Sam

 

Remember, What you think I ment may not be what I thought I ment when I said it.

 

Contributions:

 

Auto Backup your Database, Easy way

 

Multi Images with Fancy Pop-ups, Easy way

 

Products in columns with multi buy etc etc

 

Disable any Category or Product, Easy way

 

Secure & Improve your account pages et al.

Share this post


Link to post
Share on other sites

Sam / Spooks

 

I know I haved asked this previously, but I am trying to get the Quantity Price Break Per Product contribution working with your fine addon, but am getting nowhere. I want the price breaks to appear on the product listing page like they do on the product info page. In the original product listing page I could do this becuase of the two peices of code

 

Find (around line 76):

 

while ($listing = tep_db_fetch_array($listing_query)) {

 

 

Replace with:

 

// BOF qpbpp

$no_of_listings = tep_db_num_rows($listing_query);

while ($_listing = tep_db_fetch_array($listing_query)) {

$_listing['discount_categories_id'] = NULL;

$listing[] = $_listing;

$list_of_prdct_ids[] = $_listing['products_id'];

}

$list_of_prdct_ids = array_unique($list_of_prdct_ids);

 

$price_breaks_query = tep_db_query("select products_id, products_price, products_qty from " . TABLE_PRODUCTS_PRICE_BREAK . " where products_id in (" . implode(',', $list_of_prdct_ids) . ") order by products_id, products_qty");

while ($price_break = tep_db_fetch_array($price_breaks_query)) {

$price_breaks_array[$price_break['products_id']][] = array('products_price' => $price_break['products_price'], 'products_qty' => $price_break['products_qty']);

}

$discount_category_query = tep_db_query("select p.products_id, p.products_quantity, p.products_weight, discount_categories_id from " . TABLE_PRODUCTS ." p left join " . TABLE_PRODUCTS_TO_DISCOUNT_CATEGORIES . " using(products_id) where p.products_id in (" . implode(',', $list_of_prdct_ids) . ")");

while ($dc_array = tep_db_fetch_array($discount_category_query)) {

$discount_categories[] = array ('products_id' => $dc_array['products_id'], 'products_quantity' => $dc_array['products_quantity'], 'products_weight' => $dc_array['products_weight'], 'discount_categories_id' => $dc_array['discount_categories_id']);

}

for ($x = 0; $x < $no_of_listings; $x++) {

// add discount categories to the listing array

if(!empty($discount_categories)) {

for ($i = 0; $i < count($discount_categories); $i++) {

if ($listing[$x]['products_id'] == $discount_categories[$i]['products_id'] ) {

$listing[$x]['discount_categories_id'] = $discount_categories[$i]['discount_categories_id'];

$listing[$x]['products_quantity'] = $discount_categories[$i]['products_quantity'];

$listing[$x]['products_weight'] = $discount_categories[$i]['products_weight'];

}

}

} // end if(!empty($discount_categories)

}

 

// while ($listing = tep_db_fetch_array($listing_query)) { (was original code)

for ($x = 0; $x < $no_of_listings; $x++) {

 

 

Find (around line 90-135 [124-169]):

 

switch ($column_list[$col]) {

case 'PRODUCT_LIST_MODEL':

$lc_align = '';

$lc_text = ' ' . $listing['products_model'] . ' ';

break;

case 'PRODUCT_LIST_NAME':

.

.

.

.

.

.

case 'PRODUCT_LIST_BUY_NOW':

$lc_align = 'center';

$lc_text = '<a href="' . tep_href_link(basename($PHP_SELF), tep_get_all_get_params(array('action')) . 'action=buy_now&products_id=' . $listing['products_id']) . '">' . tep_image_button('button_buy_now.gif', IMAGE_BUTTON_BUY_NOW) . '</a> ';

break;

}

 

 

Replace with:

 

switch ($column_list[$col]) {

case 'PRODUCT_LIST_MODEL':

$lc_align = '';

$lc_text = ' ' . $listing[$x]['products_model'] . ' ';

break;

case 'PRODUCT_LIST_NAME':

$lc_align = '';

if (isset($HTTP_GET_VARS['manufacturers_id'])) {

$lc_text = '<a href="' . tep_href_link(FILENAME_PRODUCT_INFO, 'manufacturers_id=' . $HTTP_GET_VARS['manufacturers_id'] . '&products_id=' . $listing[$x]['products_id']) . '">' . $listing[$x]['products_name'] . '</a>';

} else {

$lc_text = ' <a href="' . tep_href_link(FILENAME_PRODUCT_INFO, ($cPath ? 'cPath=' . $cPath . '&' : '') . 'products_id=' . $listing[$x]['products_id']) . '">' . $listing[$x]['products_name'] . '</a> ';

}

break;

case 'PRODUCT_LIST_MANUFACTURER':

$lc_align = '';

$lc_text = ' <a href="' . tep_href_link(FILENAME_DEFAULT, 'manufacturers_id=' . $listing[$x]['manufacturers_id']) . '">' . $listing[$x]['manufacturers_name'] . '</a> ';

break;

case 'PRODUCT_LIST_PRICE':

$lc_align = 'right';

$price_breaks_from_listing = array();

if (isset($price_breaks_array[$listing[$x]['products_id']])) {

$price_breaks_from_listing = $price_breaks_array[$listing[$x]['products_id']];

}

$pf->loadProduct($listing[$x]['products_id'], $languages_id, $listing[$x], $price_breaks_from_listing);

$lc_text = $pf->getPriceStringShort();

break;

case 'PRODUCT_LIST_QUANTITY':

$lc_align = 'right';

$lc_text = ' ' . $listing[$x]['products_quantity'] . ' ';

break;

case 'PRODUCT_LIST_WEIGHT':

$lc_align = 'right';

$lc_text = ' ' . $listing[$x]['products_weight'] . ' ';

break;

case 'PRODUCT_LIST_IMAGE':

$lc_align = 'center';

if (isset($HTTP_GET_VARS['manufacturers_id'])) {

$lc_text = '<a href="' . tep_href_link(FILENAME_PRODUCT_INFO, 'manufacturers_id=' . $HTTP_GET_VARS['manufacturers_id'] . '&products_id=' . $listing[$x]['products_id']) . '">' . tep_image(DIR_WS_IMAGES . $listing[$x]['products_image'], $listing[$x]['products_name'], SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT) . '</a>';

} else {

$lc_text = ' <a href="' . tep_href_link(FILENAME_PRODUCT_INFO, ($cPath ? 'cPath=' . $cPath . '&' : '') . 'products_id=' . $listing[$x]['products_id']) . '">' . tep_image(DIR_WS_IMAGES . $listing[$x]['products_image'], $listing[$x]['products_name'], SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT) . '</a> ';

}

break;

case 'PRODUCT_LIST_BUY_NOW':

$lc_align = 'center';

$lc_text = '<a href="' . tep_href_link(basename($PHP_SELF), tep_get_all_get_params(array('action')) . 'action=buy_now&products_id=' . $listing[$x]['products_id']) . '">' . tep_image_button('button_buy_now.gif', IMAGE_BUTTON_BUY_NOW) . '</a> ';

break;

}

// EOF qpbpp

 

 

Obviously your code is much better for me to make the page look fantastic but I cannot get this to work. Because you pull the listing code in such a different way from the original, this is not a simple change. I assume that I could not just write a new function for this code and add it to yours as you pull the queries in differently as well. Do you have any advice for me or is this just a non starter due to other changes I would have to make on the site. I am not the greatest of coders and your help has been invaluable so far.

 

For an example of the price break table please look at http://www.omnitrack.ca/new-2010/product_info.php?products_id=51

 

Many thanks no matter what the answer

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×