Bugs of minigallery and fixes

More
13 years 4 months ago - 13 years 4 months ago #16687 by ggppdk
Problem 1:
On windows web servers the folder path used by minigallery is wrong because the paths in windows have forward slashes \.
(My development server is windows)
This results in thumbnails with a message "error messages disabled" eg when choosing and image to add to the gallery.

Fix:

Replace line 69 of file /plugins/flexicontent_fields/minigallery.php
Code:
file = '".JPATH_ROOT."/components/com_flexicontent/medias/'+file;
with:
Code:
file = '".str_replace('\\','/', JPATH_ROOT)."/components/com_flexicontent/medias/'+file;

Also in the same file change 'media' to 'medias' at lines 39 and 207


Problem 2:
Minigallery will add javascript and css to the header multiple times,
1. if more multiple minigallery fields are created and assigned to an item type
2. or flexicontent module is published and displays a minigallery field

Fix:
Check not to load javascript and css multiple times, and do some changes to allow mutiple minigallery fields.

For this we place Replace line 235 of file /plugins/flexicontent_fields/minigallery.php
Code:
if ($values) { $document->addStyleSheet('plugins/flexicontent_fields/minigallery/minigallery.css'); // this allows you to override the default css files $document->addStyleSheet(JURI::base().'/templates/'.$mainframe->getTemplate().'/css/minigallery.css'); JHTML::_('behavior.mootools'); $document->addScript('plugins/flexicontent_fields/minigallery/backgroundslider.js'); $document->addScript('plugins/flexicontent_fields/minigallery/slideshow.js'); {
with:
Code:
static $js_and_css_added = false; if ($values) { if (!$js_and_css_added) { $document->addStyleSheet('plugins/flexicontent_fields/minigallery/minigallery.css'); // this allows you to override the default css files $document->addStyleSheet(JURI::base().'/templates/'.$mainframe->getTemplate().'/css/minigallery.css'); JHTML::_('behavior.mootools'); $document->addScript('plugins/flexicontent_fields/minigallery/backgroundslider.js'); $document->addScript('plugins/flexicontent_fields/minigallery/slideshow.js'); } $js_and_css_added = true;


Problem 3:
Minigallery multiple instances (multiple fields) do not work because they use the same html tag id

Fix:
Just after the line
Code:
$js_and_css_added = true;
Add the code
Code:
$htmltag_id = "slideshowContainer_".$field->name."_".$item->id; $slidethumb = "slideshowThumbnail_".$field->name."_".$item->id;
and replace all occurences of
'slideshowContainer".$item->id."' with '$htmltag_id'
'slideshowThumbnail".$item->id."' with '$slidethumb'

Because there quite a few changes, i post a patched version of minigallery (for version 1.5.5r607), backup the original and post back feedback after testing it. And then i will add it to bug tracker.


-- Flexicontent is Free but involves a big effort on our part.
Like the our support? (for a bug-free FC, despite having a long list of functions) Like the features? Like the ongoing development and future commitment to FLEXIcontent?
-- Add your voice to the FLEXIcontent JED listing with a 5-star...
Attachments:
Last edit: 13 years 4 months ago by ggppdk.

Please Log in or Create an account to join the conversation.

More
13 years 4 months ago #16692 by micker
... incredible !
thanks for your works

FLEXIcontent is Free but involves a very big effort on our part.
Like the our support? (for a bug-free FC, despite being huge extension) Like the features? Like the ongoing development and future commitment to FLEXIcontent?
-- Add your voice to the FLEXIcontent JED listing reviews. Thanks![/size]

Please Log in or Create an account to join the conversation.

More
13 years 4 months ago #16702 by ggppdk
Thanks for sharing FlexiContent. :D


-- Flexicontent is Free but involves a big effort on our part.
Like the our support? (for a bug-free FC, despite having a long list of functions) Like the features? Like the ongoing development and future commitment to FLEXIcontent?
-- Add your voice to the FLEXIcontent JED listing with a 5-star...

Please Log in or Create an account to join the conversation.

More
13 years 4 months ago #16888 by goum
Replied by goum on topic Bugs of minigallery and fixes
Thanks !

Please Log in or Create an account to join the conversation.

More
13 years 4 months ago #17048 by lewax
Replied by lewax on topic Bugs of minigallery and fixes
Thanks for the file ggppdk.
I replace the original one with your. I noticed a small bug. When i send an image from my computer, i always have the message "invalid token"... But the image is transfered on the server.

By the way... how to delete a file??? via ftp???

cheers

Please Log in or Create an account to join the conversation.

More
13 years 4 months ago #17052 by grabit
Your problem with invlid token is solved here:
www.flexicontent.org/phpbb/viewtopic.php?f=16&t=3298

An Apple a days keeps the doctor away

Please Log in or Create an account to join the conversation.

Moderators: vistamediajoomlacornerggppdk
Time to create page: 0.491 seconds
Save
Cookies user preferences
We use cookies to ensure you to get the best experience on our website. If you decline the use of cookies, this website may not function as expected.
Accept all
Decline all
Essential
These cookies are needed to make the website work correctly. You can not disable them.
Display
Accept
Analytics
Tools used to analyze the data to measure the effectiveness of a website and to understand how it works.
Google Analytics
Accept
Decline