View Single Post
  #31  
Old 05-19-2013, 02:00 AM
 
DavyMac DavyMac is offline
 

eXpert
  
Join Date: Apr 2007
Location: Poole, UK
Posts: 333
 

Default Re: NEW xcart template - xtreme Gear

Quote:
Originally Posted by Dongan
Open a ticket directly with them http://www.thexcartstore.com/help.php

They will respond.

Thanks. If I thought that this was a bug then I would certainly raise a ticket, but what I've described is an implementation detail and I can't expect them to change their code for free.

I think the following code changes will get me the manufactuers image from the file system instead of the database. Please note that this is off the top of my head and it has not been tested. I need to set up my offline store to test this.

Somewhere within file product.php insert:
PHP Code:
/* To extract the URL of the manufacturers logo image */                    
$brand_logo_path func_query("SELECT image_path FROM $sql_tbl[images_M] INNER JOIN manufacturers ON $sql_tbl[manufacturers].manufacturerid='$product_info[manufacturerid]' AND $sql_tbl[images_M].id='$product_info[manufacturerid]'");
/* Assign the location of the image for use within the template */
$smarty->assign("logo_path"$brand_logo_path); 


Then, in file /skin/xtreme_gear/customer/main/product_details2.tpl

FIND:
Code:
<img src="image.php?type=M&amp;id={$product.manufacturerid}" alt="{$product.manufacturer}" />

REPLACE WITH:
Code:
<img src="$logo_path" alt="{$product.manufacturer}" />

By making this code change the product page will load quicker, which is why I will do this...once I can try it on an offline copy of our store.


EDIT: To see the correct code see post #40
__________________
X-Cart GOLD Plus v4.5.4
CDSEO Pro
ewdhosting Dedicated Server
Dedicated SSL
Stone Edge OM
Reply With Quote