• Resolved bigkrp

    (@bigkrp)


    If i have “Mouse-over box” on, when i click “continue” my page is reloading.
    It’s happens because <a> has empty href attribute. To fix this i propose

    footnotes/class/task.php:372

    should be like that
    $l_str_ExcerptText .= " ..." . sprintf(__("%scontinue%s", MCI_Footnotes_Config::C_STR_PLUGIN_NAME), '<a href="#" onclick="footnote_moveToAnchor(\'footnote_plugin_reference_'.$l_str_Index.'\', event);">', '</a>');

    And in footnotes/templates/public/reference-container.html:28 it would be worth modifying the function:

    
    function footnote_moveToAnchor(p_str_TargetID, e) {
    		if (e instanceof MouseEvent) {
    			e.preventDefault();
    		}
    
    		footnote_expand_reference_container();
            var l_obj_Target = jQuery("#" + p_str_TargetID);
            if(l_obj_Target.length) {
                jQuery('html, body').animate({
                    scrollTop: l_obj_Target.offset().top - window.innerHeight/2
                }, 1000);
            }
        }
    
Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Contributor pewgeuges

    (@pewgeuges)

    Sadly this is one of the big bugs in footnotes. To fix it, you don’t need the preventDefault method, just accurately set the default to following the precise fragment identifier. This works for me:

    
    $l_str_ExcerptText .= '&nbsp;… ' . sprintf(__("%scontinue%s", MCI_Footnotes_Config::C_STR_PLUGIN_NAME), '<a class="continue" href="#footnote_plugin_reference_' . self::$a_str_Prefix.$l_str_Index . '" onclick="footnote_moveToAnchor(\'footnote_plugin_reference_' . self::$a_str_Prefix . $l_str_Index . '\');">', '</a>');
    

    That also concatenates the random prefix missing in this instance. I recommend disabling the random prefix, but the fix here is to add it as intended.

    • This reply was modified 5 years, 7 months ago by pewgeuges.
    • This reply was modified 5 years, 7 months ago by pewgeuges.
    • This reply was modified 5 years, 7 months ago by pewgeuges.
    • This reply was modified 5 years, 7 months ago by pewgeuges.
    • This reply was modified 5 years, 7 months ago by pewgeuges.
    • This reply was modified 5 years, 7 months ago by pewgeuges.
    Plugin Contributor pewgeuges

    (@pewgeuges)

    This problem is now solved as a part of v2.0.0 released today.

    Sorry for the delay.

    Thanks for the update. It’s working on one blog but not another.

    On the one that is working, however, an underscore line is appearing under the footnote. See: https://www.markmallett.com/blog/dear-holy-father-he-is-coming/

    Okay, so this is what I’ve found.

    – In Safari, the footnote looks correct: it is superscript and no line underscore.

    – In Firefox, the footnote is not superscript and has the underscore.

    – In Google-based browsers, there is no superscript and no underscore.

    This is not happening with another footnotes plugin I’m testing.

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘Mouse-over box `continue` bug’ is closed to new replies.