Viewing 15 replies - 1 through 15 (of 21 total)
  • Plugin Author Mark Jeldi

    (@mark-jeldi)

    Hi samaralife,

    Thanks for using NextGEN Gallery Optimizer!

    In regards to the long titles in Fancybox, this is because the default “float” title display is unable to accommodate line breaks. However, there are three other styles you can choose from that will. To switch styles, simply open nextgen-gallery-optimizer/nextgen-optimizer-scripts-and-styles.php and replace the “fancybox inline js” section at the top with the following…

    /**********************************************************************
    * fancybox inline js
    **********************************************************************/
    
    function nggo_fancybox_inline_js() { ?>
    <!-- [nextgen gallery optimizer v<?php echo NGGO_VERSION; ?>] This page must contain a nextgen shortcode...else we wouldn't be serving its scripts and styles -->
    <script type='text/javascript'>jQuery.noConflict(); jQuery(document).ready(function() { jQuery('a.myfancybox').fancybox({ 'zoomSpeedIn':500, 'zoomSpeedOut':500, 'overlayShow':true, 'overlayOpacity':0.3, 'titlePosition':'over'}); });</script>
    <?php
    }

    In the above example, I’ve simply appended ‘titlePosition’:’over’ to instruct Fancybox to use an overlay for titles, but you can also set ‘titlePosition’:’inside’ or ‘titlePosition’:’outside’ for multi-line titles.

    In regards to your second question, Fancybox uses NextGEN’s “Description” field at Gallery --> Manage Gallery --> gallery_name for your lightbox image titles. Looking at the source code from your second link, you only seem to have the “Alt/Title” field populated for each image. Type or copy/paste a description for each image, and they will display automatically in the lightbox.

    Hope this helps!

    Cheers,
    Mark.

    Thread Starter samaralife

    (@samaralife)

    Hi and thank you for the suggestions.

    As for the long titles, I’ll think about it.

    As for the absence of descriptions under the pics in galleries, I do have descriptions (both Alt/Title and Description fields are filled in) yet no description (or title) appears. Mind you, it used to be visible until recently. I guess something was changed in the plugin code or functionality with the latest update.

    NB: By descriptions I mean the title of the picture that I write in the description box, not the title (automatically filled in and equalling the name of the file) in the upper field at each picture in “Manage the Gallery”.

    Plugin Author Mark Jeldi

    (@mark-jeldi)

    Hey samaralife,

    Thanks for the update. I’ve just had another look through your source code, and I believe I know why your descriptions aren’t showing…

    Your theme is actually loading another instance of Fancybox, including its stylesheet, js file and another invocation code tucked away in wp-content/themes/origin/js/footer-scripts.js.

    This footer-scripts.js file is essentially overriding the settings for Optimizer’s Fancybox, and is setting titleShow: false…hiding your descriptions.

    Ideally, if you want to continue using Optimizer’s Fancybox (and only load the necessary scripts and styles on pages with the [nggallery id=x] shortcode), it would be best to remove these sitewide Fancybox files from your theme. But for a quick fix, you could probably just remove or comment out the /* Fancybox */ block in your footer-scripts.js file.

    Hope this helps!

    Cheers,
    Mark.

    PS. The 'titlePosition':'outside' setting you’ve gone for will show your descriptions in white text, so you may want to darken the lightbox overlay (for higher contrast) by changing 'overlayOpacity':0.3 to a higher value (max is 1).

    Thread Starter samaralife

    (@samaralife)

    Hi Mark,

    Thanks for the update. I have looked into the theme files and see that Fancybox is not just a footer-related thing. I now realise why thumbnail pics (after I changed the theme to the current one) started showing with the Fancybox effect instead of just in a separate window like I set them.

    I am afraid I won’t be able to safely delete the Fancybox from the theme files. I cannot be certain that deleting it won’t ruin the theme functionality. Besides, I like how thumbnails are showing.

    I guess I will have to disable the plugin. Though here there’s another mystery. When I disabled it a few days ago, the pics in galleries started behaving weirdly – they were shown in both NGG own style (with description) and Fancybox style.

    Anyway, thanks for your help.

    Thread Starter samaralife

    (@samaralife)

    Actually, I deleted Fancybox part from the footer js file you mentioned and changed the opacity to 1 and it worked – I have descriptions! Long descriptions are also fully visible!

    Thank you so much!

    Andy

    Plugin Author Mark Jeldi

    (@mark-jeldi)

    Hey Andy,

    No worries. Glad I could help.

    Quick tip: If you want to adjust the overlay color, you can also add ‘overlayColor’:’#666′ (replacing #666 with your desired hex color code).

    Cheers,
    Mark.

    fredel

    (@fredel)

    Hey Mark,

    sorry for reopening but i got a similar issue. would be great if you may have a look at https://bergtour-online.de/allgemein/gallerytest/

    the titles are not shown even i changed the nextgen-gallery-optimizer/nextgen-optimizer-scripts-and-styles.php – but it seems its inactive but i cannot find anything in the footer.

    thx so much,
    fritz

    Plugin Author Mark Jeldi

    (@mark-jeldi)

    Hey Fritz,

    I’ve just been looking through your source code. The reason you’re not seeing titles in Fancybox is because you don’t have the title=”” attribute present on your image anchor tags.

    It looks as though you’ve edited NextGEN’s gallery template…is this correct? The HTML structure is rather different than the default. If so, you’ll need to add the title attribute back in (and maybe lose the closing p tags too so it validates).

    If you need the original file again to start over, just download the NextGEN Gallery zip file to your computer and copy the template file (nextgen-gallery/view/gallery.php) to the same directory on your server.

    Hope this helps!

    Cheers,
    Mark.

    PS. You’ll also need to make sure your images have their “Description” field filled in at Gallery –> Manage Gallery –> “your_gallery_name” for titles to display.

    fredel

    (@fredel)

    Hey Mark, thanks very much for the detailed feedback!
    i will check this up, even i didnt made any changes – maybe my buddy did! thx so much
    fritz

    fredel

    (@fredel)

    sorry again, just updated nextgen so ist should habe the original source code. problem still exists ;(

    Plugin Author Mark Jeldi

    (@mark-jeldi)

    Hey Fritz,

    You may want to check your currently active theme for a folder named “nggallery”. Any template files in that folder are designed to override the originals, and won’t be touched during a plugin upgrade.

    If that folder isn’t present, you may also want to check that NextGEN’s HTML output hasn’t been hard-coded into your post/page via the editor or a page template.

    Cheers,
    Mark.

    fredel

    (@fredel)

    hey mark,

    thanks again! checked this, cant find the folder in the the dir and theres also no html in the article php.

    huuummmm….

    best regards
    fritz

    fredel

    (@fredel)

    i have some plugins within the theme that come by default, eg
    dp-flickr-widget, gallery-to-slideshow & tabber-tabs-widget

    do you think this may cause an issue…

    i know its not your business but maybe you find some minutes checking this ??

    thxxx

    fredel

    (@fredel)

    PS: nextgen-gallery/view/gallery.php ist shown as (inaktive)

    Plugin Author Mark Jeldi

    (@mark-jeldi)

    Hey Fritz,

    How puzzling! ??

    There could be a conflict somewhere, but it’s difficult to detect anything further from the front-end. If you’d like to email me a temporary administrator login for your site, I’d be happy to take a look for you.

    It’s okay that the gallery.php file shows as inactive. That’s just because it’s not being loaded in the admin.

    Cheers,
    Mark.

    PS. Thanks for the donation too…that’s much appreciated!

Viewing 15 replies - 1 through 15 (of 21 total)
  • The topic ‘[Plugin: NextGEN Gallery Optimizer] Issues with Image Description’ is closed to new replies.