WordPress.org

Ready to get started?Download WordPress

Forums

jQuery Notify
[resolved] Delay and option override (2 posts)

  1. jefs42
    Member
    Posted 1 year ago #

    Hello, this plugin is great and exactly what I was trying to find.

    However, I ran into a couple "issues".

    First off, using the template code, it wasn't letting me change any settings such as style. I found in the code that it always just uses $options['style'], etc and doesn't take into account the variables being passed. I modified that code to check like

    $style = isset($style) ? $style : $options['style'];

    for each option and then calling template_tag like

    $jquery_notification->template_tag($content, $style, $speed, $delay);

    Also, the box would never automatically hide after the set delay ( even after modifying the above to use my passed values ). Maybe a jQuery version issue or something? Not sure, but I added this to the document.ready code in script.js

    setTimeout(function(){
      $('.jqnm_message').animate({top: -$('.jqnm_message').outerHeight()}, parseInt(jqnm_script_vars.speed));
    },jqnm_script_vars.delay);

    Again, thanks for making this and except for the above minor issues, at least for me, works like a charm. Hope the above helps anyone else.

    http://wordpress.org/extend/plugins/jquery-notify/

  2. Bryce Corkins
    Member
    Plugin Author

    Posted 1 year ago #

    Thanks for pointing that out, and providing your solution... I just updated the plugin to 0.3 and incorporated your suggested code.

    The "delay" property was actually meant to set a delay between document.ready and when the notification appears. I added a new option in the options pane to enable auto-hiding the notification pane, and to set a delay on when the auto-hide happens.

    Cheers.

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic

Tags

No tags yet.