Page 1 of 1

Tags does not work anymore after installing Phoca open graph

Posted: 19 Jul 2016, 14:51
by kazemgh
Hi
I have some menu Items based on tags. but they stops working after installing Phoca open graph with this error:

Code: Select all

Fatal error: Call to a member function get() on null in /home/microna1/public_html/plugins/content/phocaopengraph/phocaopengraph.php on line 245
this happens when I click on tags below articles too.
any chance to make it right!? :(

here is a sample link to error page:
http://micronarrative.ir/index.php/archive/1350s.html

Re: Tags does not work anymore after installing Phoca open graph

Posted: 21 Jul 2016, 22:54
by Jan
Hi, which version of the plugin you run, can you paste a link without SEF, so I can test in on my test server.

On the row, there is this code:
$this->params->get

which is standard code to get the plugin params, for example:
plugins\content\loadmodule\loadmodule.php
$style = $this->params->def('style', 'none');

:idea:

Jan

Re: Tags does not work anymore after installing Phoca open graph

Posted: 23 Jul 2016, 20:06
by kazemgh
Thank you for reply :)

Here is same link without SEF:
clicking on a tag menu item:
http://micronarrative.ir/index.php?opti ... Itemid=324

cliking on same tag link below article:
http://micronarrative.ir/index.php?opti ... Itemid=324

Re: Tags does not work anymore after installing Phoca open graph

Posted: 25 Jul 2016, 17:50
by Jan
Hi, than you very much for the info:

Please open:

and change
FROM:

Code: Select all

if ($app->getName() != 'site') { return;}
TO:

Code: Select all

if ($app->getName() != 'site') { return;}
if ($view == 'tag') { return; }
This should help, let me know if it works for you.

Thank you, Jan

Re: Tags does not work anymore after installing Phoca open graph

Posted: 26 Jul 2016, 11:28
by tastymouse
In which file do we have to change the code?

Edit: the answer is plugins/content/phocaopengraph/phocopengraph.php

Re: Tags does not work anymore after installing Phoca open graph

Posted: 26 Jul 2016, 20:54
by jsolis
I'm not sure if I'm having the same issue. The site is: esfacilserverde.com/portal25/crecimiento-de-consciencia/255-viviendo-de-la-manera-dificil

When I share on FB, it appears this:

http://www.digilibro.com/soporte/phoca1.jpg

I have installed and activated 3 phoca plugins

http://www.digilibro.com/soporte/phoca2.jpg

The metatags generated are this (from "view source code"). I don't know where the last tags are being generated, because I can see the correct ones (og:) are before those, and why the FB share is using the description tag insted of the og:description tag. Any idea on solving this?


<meta name="viewport" content="width=device-width, initial-scale=1.0">
<base href="http://esfacilserverde.com/portal25/cre ... ra-dificil" />
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
<meta name="keywords" content="custom keys for seo" />
<meta name="rights" content="custom rights for seo" />
<meta name="og:title" content="Viviendo de la manera difícil" />
<meta name="og:type" content="article" />
<meta name="og:image" content="http://www.esfacilserverde.com/portal25 ... ficil1.jpg" />
<meta name="og:url" content="http://esfacilserverde.com/portal25/cre ... ra-dificil" />
<meta name="og:site_name" content="Es fácil ser verde" />
<meta name="og:description" content="Todo este año me he preguntado ¿por qué hacemos la cosas de la manera difícil? Seguramente es mucho más fácil obtener un trabajo de 9 a 6, manejar un carro nuevo, tener una casa bonita, comprar toda nuestra comida en el supermercado y, en resumidas cuentas, tener una &quot;vida normal&quot;" />
<meta name="author" content="Es fácil ser Verde" />
<meta name="description" content="custom description for seo" />
<meta name="generator" content="custom generator for seo" />

<title>Viviendo de la manera difícil</title>

Re: Tags does not work anymore after installing Phoca open graph

Posted: 26 Jul 2016, 21:18
by kazemgh
Jan wrote: change
FROM:

Code: Select all

if ($app->getName() != 'site') { return;}
TO:

Code: Select all

if ($app->getName() != 'site') { return;}
if ($view == 'tag') { return; }
WORKED!! :D
THANK YOU SO MUCH!!

Re: Tags does not work anymore after installing Phoca open graph

Posted: 26 Jul 2016, 23:22
by Jan
Ok, set in version 3.0.7

https://www.phoca.cz/download/category/6 ... aph-plugin

Thank you for the info,
Jan

Re: Tags does not work anymore after installing Phoca open graph

Posted: 26 Jul 2016, 23:24
by Jan
jsolis
<meta name="description" content="custom description for seo" />
<meta name="generator" content="custom generator for seo" />
These tags are not set by Phoca Opengraph plugin.