Viewing 15 replies - 1 through 15 (of 16 total)
  • Thread Starter TiKu

    (@tiku)

    I suggest to pass the shortcode’s style name to enqueue_ngg_styles and modify enqueue_ngg_styles, so that it doesn’t call wp_enqueue_style directly anymore. Instead it should collect the passed style names in an array and make sure that another action handler is setup which will be executed after all shortcodes have been processed. This action handler then should call wp_enqueue_style for nggallery.css, passing the collected shortcode styles as dependencies array (3rd parameter of wp_enqueue_style).
    Unfortunately I don’t know which action to attach the action handler to.

    @tiku,

    Hi I think I have a very similar problem but I am calling do_shortcut twice in a PHP template for my theme.

    http://wordpress.org/support/topic/css-conflicts-and-highslide-not-working?replies=1

    Is it the same issue?

    Thread Starter TiKu

    (@tiku)

    I’m not sure, but you can check it easily. Open the post and then make your web browser display the source code of the page. Search the code for <link rel=’stylesheet’ id=’nggallery-css’
    If there come other stylesheet inclusions after this line, and those have an id that starts with ‘nextgen_’, then you suffer from the problem that I’ve described.
    In my case NextGen includes the CSS for basic_singlepic, then the custom nggallery-css, and then the CSS for basic_thumbnails. It should include the nggallery-css at the end, after any other NextGen CSS definition.

    Thread Starter TiKu

    (@tiku)

    To whomever deleted my bump posts: This is a major bug which prevents us from upgrading. Instead of removing the posts, you should fix this bug or at least provide a workaround.

    Thread Starter TiKu

    (@tiku)

    Still broken in 2.0.30.

    Thread Starter TiKu

    (@tiku)

    Still broken in 2.0.33.

    Thread Starter TiKu

    (@tiku)

    Still broken in 2.0.40.

    Thread Starter TiKu

    (@tiku)

    Still broken in 2.0.59.

    Thread Starter TiKu

    (@tiku)

    Will this ever be fixed?

    Plugin Contributor photocrati

    (@photocrati)

    @tiku – What are you seeing with the latest version of NextGEN Gallery (2.0.66.16)?

    If this is still not working as you would like, what specifically are you doing to create the issue?

    Thanks!

    – Cais.

    Thread Starter TiKu

    (@tiku)

    With 2.0.66.16 it is still broken. I want to use different kinds of NextGen galleries on the same page and want to customize the CSS. For instance I want to use the singlepic shortcode and afterwards (on the same page) the nggallery shortcode. I want to customize the styling of the nggallery navigation with this CSS:

    .ngg-navigation a.page-numbers:hover,
    .ngg-navigation a.next:hover,
    .ngg-navigation a.prev:hover,
    .ngg-navigation span.page-numbers:hover,
    .ngg-navigation span.next:hover,
    .ngg-navigation span.prev:hover {
    	background-color: #006C36;
    }

    I place the CSS in the file wp-content/ngg_styles/nggallery.css and enable these customizations in the NextGen settings.
    Looking at the generated HTML code, I can see nggallery.css being loaded. But it is not loaded after all other NextGen CSS files. Instead it is loaded right after the first one.
    So NextGen loads nextgen_basic_singlepic.css (because of the singlepic shortcode), then my custom nggallery.css, then some other CSS files, including nextgen_pagination/static/style.css which overrides my customizations.

    Of course I could mark my custom CSS definitions as !important, but I would not consider it a good solution (and as far as I remember I already tried it and ran into some new problems that I could not solve).
    So best would be if custom styles would always be loaded after the last default CSS file of NextGen Gallery. This already is the case if you use only one kind of gallery per page. But as soon as you use more than one, problems arise.

    TiKu

    Plugin Contributor photocrati

    (@photocrati)

    @tiku – I have written up this issue to be reviewed and agree it should be addressed. I also agree the use of !important should not be a default necessity (but may be the best work-around at this time).

    Thanks fro bringing this back to our attention.

    – Cais.

    Yes I can confirm that to… In album page it works, but in gallery overview page it includes all gallery CSS after my custom stylesheet…
    And why there is no possibility to disable all nggallery stylesheets and have my own one file? In that way I can get control over all styles, no overriding nothing. Or like in other case just let me have same file that I want to override in wp-content/ngg_styles folder: if the file exist in that folder do not load it from plugin folder. Or even there could be a option in configuration to not load default plugin CSS files, and another option to load CSS files from that ngg_styles folder. SO I can ake my own stylesheets, minimize them etc. This will also save some queries to server…

    Plugin Contributor photocrati

    (@photocrati)

    @vytas M. – Please start your own topic rather than continuing to bring this old topic back to the front.

    Thanks!

    – Cais.

    Thread Starter TiKu

    (@tiku)

    Well, as long as the problem is not solved, the topic is not really old. As the starter of this topic I’m absolutely fine with another user posting a related message to it.

    TiKu

Viewing 15 replies - 1 through 15 (of 16 total)
  • The topic ‘Custom Style (nggallery.css) is not ensured to be enqueued as last style’ is closed to new replies.