1. Hackwar
  2. Features Request
  3. Sunday, October 22 2017, 02:22 PM
Hi,
I have a website that displays 2 different galleries in the profile tabs. I use the Joomgallery for this and the Joomgallery-Plugin. However, in order to display more than one tab, I have to copy the plugin. That also means any code changes have to be done twice, etc. It would be good if one plugin could provide more than one tab in the profile tabs. I fear that this would require an at least partially backwards incompatible change, but I would propose that tab plugins can either return an object or an array of objects. Each object would be a tab and have the attributes "title", "content". That would allow to later add additional attributes, like maybe "script" or "scriptfile". It would also provide a (clearer) interface for the development of such a plugin.

A backwards compatible way to implement this would be by doing the following:

foreach($tabs as $tab)
{
if (is_object($tab[0]))
{
foreach ($tab as $tabobject)
{
$contents[]='<fieldset><legend>'.$tabobject->title.'</legend>'.$tabobject->content.'</fieldset>';
}
}
else
{
$contents[]='<fieldset><legend>'.$tab[0].'</legend>'.$tab[1].'</fieldset>';
}
}


Would you be interested in adding this? The downside would be, that multiple tabs would always show up next to each other in the order of the plugins. But that would be acceptable for me...

I've recently joined the Joomgallery Project and I will rewrite the Joomgallery Plugin. If you are interested, you could also provide it here, maybe alongside your version, maybe as a replacement.
admin Accepted Answer
Admin
Hi Hannes,
Would you be interested in adding this?
No problem about this, in next release we will add this code.

If you are interested, you could also provide it here, maybe alongside your version, maybe as a replacement.
Great, we can remove our plugin and put a link to your plugin page.
  1. more than a month ago
  2. Features Request
  3. # 1
  • Page :
  • 1


There are no replies made for this post yet.
However, you are not allowed to reply to this post.