Social 2s as a module (or why it is not possible)

28 Nov 2015 22:44 #56 por anton
Many people ask about the possibility of showing plugins in a module.

Let's see how social 2s works.

In first place, social 2s is a plugin. In joomla!, a plugin is triggered only when is called (with the specific function afterDisplayContent, beforeDisplayContent...).
So, the component must call for plugins with those functions. Virtuemart or other components have an options to enable plugins.

Ok, but we always could insert a module and display social 2s in any component and any position. Isn't it?
Not really... We tried, but there are a few problems to deal with the correct work of social plugins.

First of all, Fb and Linkedin use Opengraph, so we need to insert several data as "title", "image", "description...".
Social 2s as a module doesn't guarantee the extraction of that data from the page (and the plugin fails to display an incorrect information. Not admissible).
We could use the page data, but the possibilities of error or impossibility to find the data are too big.
The same thing with Twitter cards.

Secondly, there are many components which use a "category view". In those cases, what information will be passed to the buttons? The page information is not correct (all the plugin buttons will display the information of the first article...).

In com_content component, we need to find the information of every article displayed. We need to do that manually in every component with "category view".

There are a few other reason to not publish a social2s module (we did in 1.x version and we had to remove it).

We think that the best solution with guarantees is to add supporting for more components manually.
We are currently working to support Jevents and we hope to launch a new version soon ;)

if you find useful our plugins, spread the word in JED!

Por favor, Identificarse para unirse a la conversación.

Moderadores: anton