Jump to content

Adding alt img tags to an existing php website


jamesm489

Recommended Posts

I am currently tring to add in alt img tags for an existing website running the interspire shopping cart platform, I have gotten pretty close I bleieve, but i cannot seem to get it right. Any help would be grealty appreciated.

 

 

 

			// Is there a thumbnail image we can show?
		$thumb = $GLOBALS['ISC_CLASS_PRODUCT']->GetThumb();
		$alttext = $GLOBALS['ISC_CLASS_PRODUCT']->GetProductName();

		if($thumb == '' && GetConfig('DefaultProductImage') != '') {
			if(GetConfig('DefaultProductImage') == 'template') {
				$thumb = GetConfig('ShopPath').'/templates/'.GetConfig('template').'/images/ProductDefault.gif';
			}
			else {
				$thumb = GetConfig('ShopPath').'/'.GetConfig('DefaultProductImage');
			}
			$thumbImage = '<img src="'.$thumb.'" alt="'.$GLOBALS['ISC_CLASS_PRODUCT']->GetProductName().'" />';
		}
		else if($thumb != '') {
		$thumbImage = '<img src="'.GetConfig('ShopPath').'/'.GetConfig('ImageDirectory').'/'.$thumb.'" alt="'.$alttext.'" />';

		}

Archived

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

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.