Brand Image match product page

General ShopSite user discussion

Brand Image match product page

Postby dgroff » Tue Aug 09, 2011 8:17 am

When a user comes across one of our product pages, I want the brand logo to automatically generate itself and post to the page. How do I set this up so it automatically pulls the image of the brand?

Example:
Visit a Miller Electric product, I want the Miller Electric logo to display on that page.
dgroff
 
Posts: 28
Joined: Fri May 27, 2011 8:43 am

Re: Brand Image match product page

Postby ShopSite Lauren » Tue Aug 09, 2011 9:46 am

You can always manually add in images/logos in the product description or product text fields, but if you want the logo to be something that is added automatically, it is something that needs to be done with a custom product template. Here are two ways of doing it:

1 - use the Google Brand field, custom product template, and custom include file.

- start by going to Merchandising > Custom Templates > Includes > Create A New Include. Name the include "BrandNames" and save changes.
- next, edit the include file. Start with an if statement for your first brand, [-- IF Product.Brand "Miller Electric" --] then add the code for your image. For more brands add [-- ELSE_IF PRODUCT.Brand "brand name" --] and their image. End with an [-- END_IF --]. So your code will end up looking something similar to the following:
[-- IF PRODUCT.Brand "Miller Electric" --]
<img src="http://www.mystore.com/media/millerelectric.jpg" border="0" alt="Miller Electric Product">
[-- ELSE_IF PRODUCT.Brand "Premiere Electric" --]
<img src="http://www.mystore.com/media/premiereelectric.jpg" border="0" alt="Premiere Electric Product">
[-- END_IF --]

- after saving changes, you can go to your custom product template and add in [-- INCLUDE BrandNames PROCESS --] where you want the brand logos to appear.
- last, make sure your products are using your custom product template (Products > Edit Product Layout), then type in the brand names (exactly as you added them in the include file) under Products > Edit Product Info > Google Brand.
- publish and view.


2 - use the page graphic and a custom page and product template.

- start by going to merchandising > custom templates > page/product. In your custom page template, add [-- VAR.Brand PAGE.Graphic --] to the very top of the template, just below the [-- DEFINE PAGE --] tag.
- save changes, then in your product template, add [-- IF VAR.Brand --][-- VAR.Brand --][-- END_IF --] where you want the brand logo to appear.
- after saving changes, you can go to Pages > Edit Page Layout, and make sure you have the brand logo assigned as the page banner graphic and that the correct products are assigned to that brand page.
- save changes and publish.


The first method I mentioned is based of the product and the product brand field only. The second method is not as exact, as it is based on what products are assigned to which pages. If a product appears both in a brand page and a type page (such as in the "Engines" page and the "Miller" page) it may not have the brand graphic assigned.
- ShopSite Lauren
Contact me for help with any of your
custom ShopSite template questions.
ShopSite Lauren
 
Posts: 889
Joined: Fri Aug 11, 2006 1:35 pm
Location: Orem, UT


Return to User Forum

Who is online

Users browsing this forum: No registered users and 94 guests