Jump to content

Sitemap generator - HTTPS in images


vistoh

Recommended Posts

Hi,

 

I have SSL protocol activated in my whole ecommerce and I have realized that in my XML sitemap, the image url has not the https (it has only http). All urls products have https then why the image urls haven't? I understand that they should have also https in

 

My PS is 1.6.1.4 and Gsitemap module v 3.2.1 and I have only 1 shop. "Enable SSL in all pages" = Yes

 

In gsitemap.php there is this code

if (isset($id_image['id_image']))
			{
				$image_link = $this->context->link->getImageLink($product->link_rewrite, $product->id.'-'.(int)$id_image['id_image'], 'large');
				$image_link = (!in_array(rtrim(Context::getContext()->shop->virtual_uri, '/'), explode('/', $image_link))) ? str_replace(
					array(
						'https',
						Context::getContext()->shop->domain.Context::getContext()->shop->physical_uri
					), array(
						'http',
						Context::getContext()->shop->domain.Context::getContext()->shop->physical_uri.Context::getContext()->shop->virtual_uri
					), $image_link
				) : $image_link;
			}
Edited by vistoh (see edit history)
Link to comment
Share on other sites

  • 1 month later...

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
×
×
  • Create New...