Author Topic: Integration of Google Certified Shop  (Read 371 times)

Holger

  • Beginner
  • *
  • Posts: 17
Integration of Google Certified Shop
« 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
Code: [Select]
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

Studio 42

  • Contributing Developer
  • Full Member
  • *
  • Posts: 2112
  • Joomla & Virtuemart addon developper
    • Studio 42 - Virtuemart & Joomla extentions
  • VirtueMart Version: 2.6 &amp; 3.0.x.y
Re: Integration of Google Certified Shop
« Reply #1 on: January 04, 2017, 15:35:55 pm »
Try a var_dump($order), i think it not exist, so perhaps $this->order work ?

Holger

  • Beginner
  • *
  • Posts: 17
Re: Integration of Google Certified Shop
« Reply #2 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

Studio 42

  • Contributing Developer
  • Full Member
  • *
  • Posts: 2112
  • Joomla & Virtuemart addon developper
    • Studio 42 - Virtuemart & Joomla extentions
  • VirtueMart Version: 2.6 &amp; 3.0.x.y
Re: Integration of Google Certified Shop
« Reply #3 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.

jenkinhill

  • UK Web Developer & Consultant
  • Global Moderator
  • Super Hero
  • *
  • Posts: 25820
  • Always on vacation
    • Jenkin Hill Internet
Kelvyn

Jenkin Hill Internet,
Keswick, Lake District

Unsolicited PMs/emails will be ignored.

Please mention your VirtueMart, Joomla and PHP versions when asking a question in this forum

Currently using VM3.2.3 on Joomla 3.7.2 PHP 7.0.19

Testing VM3.2.3 on J!3.7.2

Holger

  • Beginner
  • *
  • Posts: 17
Re: Integration of Google Certified Shop
« Reply #5 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...

Studio 42

  • Contributing Developer
  • Full Member
  • *
  • Posts: 2112
  • Joomla & Virtuemart addon developper
    • Studio 42 - Virtuemart & Joomla extentions
  • VirtueMart Version: 2.6 &amp; 3.0.x.y
Re: Integration of Google Certified Shop
« Reply #6 on: January 05, 2017, 01:48:24 am »
Try
Code: [Select]
var_dump($order);
var_dump($this->order);
jexit();
to check what is correct and you get all values displayed in the order object

Holger

  • Beginner
  • *
  • Posts: 17
Re: Integration of Google Certified Shop
« Reply #7 on: January 11, 2017, 13:02:06 pm »
Thanks, i tried, but i only get NULL NULL as answer.

Studio 42

  • Contributing Developer
  • Full Member
  • *
  • Posts: 2112
  • Joomla & Virtuemart addon developper
    • Studio 42 - Virtuemart & Joomla extentions
  • VirtueMart Version: 2.6 &amp; 3.0.x.y
Re: Integration of Google Certified Shop
« Reply #8 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+