VirtueMart Forum

VirtueMart 2 + 3 + 4 => General Questions => Topic started by: Holger on January 04, 2017, 15:03:34 PM

Title: Integration of Google Certified Shop
Post by: Holger on January 04, 2017, 15:03:34 PM
Is anybody using Google Certified Shop with Virtuemart 2.0.22 and can give me the code snippet for integration?
I try it since hours, but with no success.
I tried to integrate in order_done.php. For example for the order number with
echo '<span id="gts-o-id">';
echo $order['details']['BT']->order_number;
echo '</span>';

but the resulting SPAN is empty.
Maybe anybody has a hint, what is wrong.

Thanks
Holger
Title: Re: Integration of Google Certified Shop
Post by: Studio 42 on January 04, 2017, 15:35:55 PM
Try a var_dump($order), i think it not exist, so perhaps $this->order work ?
Title: Re: Integration of Google Certified Shop
Post by: Holger on January 04, 2017, 16:02:55 PM
Thanks for answer, but i'm sorry, i don't know what i have to change. My PHP knowledge is very weak.
Can you give a code snippet, please?

Thanks
Holger
Title: Re: Integration of Google Certified Shop
Post by: Studio 42 on January 04, 2017, 17:35:41 PM
Sorry, it's a little long to do it.
But here you have the way to do it : https://www.google.co.uk/intl/en/retail/certified-shops/get-started/
You need to implement the badge code and the  order confirmation module code
badge code is for your whole shop (easy way is to modify the template) and  order confirmation module code is in order_done.php file.
And remember that VM2.0.22 is a very old release so perhaps it's better for you to upgrade VM+Joomla to have no hacking problem in Vm and Joomla.
Title: Re: Integration of Google Certified Shop
Post by: jenkinhill on January 04, 2017, 17:41:28 PM
Quote from: Holger on January 04, 2017, 15:03:34 PM
Virtuemart 2.0.22

Please see http://forum.virtuemart.net/index.php?topic=118683.0
Title: Re: Integration of Google Certified Shop
Post by: Holger on January 04, 2017, 22:23:35 PM
Thanks, i know the way for integration. The badge is working. The problem is only the filling of the order confirmation module...
Title: Re: Integration of Google Certified Shop
Post by: Studio 42 on January 05, 2017, 01:48:24 AM
Try
var_dump($order);
var_dump($this->order);
jexit();

to check what is correct and you get all values displayed in the order object
Title: Re: Integration of Google Certified Shop
Post by: Holger on January 11, 2017, 13:02:06 PM
Thanks, i tried, but i only get NULL NULL as answer.
Title: Re: Integration of Google Certified Shop
Post by: Studio 42 on January 11, 2017, 13:37:51 PM
sorry, but i cannot check in vm2.0.22, perhaps this value only exist in vm 2.6+