• Resolved saskiawater

    (@saskiawater)


    Hello,

    is there a possibility do deactivate the collapsing functionality? Or alternatively, can I hide the [+] in the title?

    As I see, you can only set the default view, if it’s going to collapes or not.

    The reason is, that I’m using a Table of Contents plugin and the title (I’m using H2) is also shown there, what I want, but it also shows the [+], what I don’t want.

    Thanks for the support!

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Contributor pewgeuges

    (@pewgeuges)

    @saskiawater

    The setting to remove the [+] is missing. But you may customize the template instead, and then store it outside the plugin (in another plugin or in the active theme). The customized template stack, that Footnotes owes to @misfist, was described in the plugin folder. Since that file has been removed from distribution two weeks ago, an easy way to access the information is now online at https://plugins.trac.wordpress.org/browser/footnotes/trunk/customized-template-stack.txt?rev=2498648

    E.g. you would add wp-content/plugins/footnotes-custom/templates/public/reference-container.html and delete the following code:

    
    <span
    				role="button"
    				tabindex="0"
    				class="footnote_reference_container_collapse_button"
    				style="[[button-style]]"
    				onclick="footnote_expand_collapse_reference_container_post_id_container_id();"
    			>[<a
    				id="footnote_reference_container_collapse_button_post_id_container_id"
    			>+</a
    			>]</span
    			>
    

    I’m sorry for not being more helpful.

    Thread Starter saskiawater

    (@saskiawater)

    You helped me. Although it is still collapsable but now it looks as I wanted to.

    Thank you!

    But the theme files are not loaded from templates/footnotes/ folder in my child theme. I changed it in the plugin folder, which means, that my changes will be gone in next update.

    Edit: The sibling-folder works. No idea why it does not work in the child template folder.

    • This reply was modified 2 years, 11 months ago by saskiawater.
    • This reply was modified 2 years, 11 months ago by saskiawater.
    Plugin Contributor pewgeuges

    (@pewgeuges)

    @saskiawater

    I’m sorry for the bug. I must confess that I hadn’t tested it in a child theme, although I should have, but it works in a plugin folder, if the path is wp-content/plugins/footnotes-custom/templates/public/reference-container.html.

    On your feedback I quickly caught up on testing and was baffled that it only works in a plugin folder. I can’t figure out why it doesn’t work in a child theme—that I swiftly got generated to store the custom template at wp-content/themes/gpchild/templates/footnotes/public/reference-container.html.
    I don’t understand the origin of this bug even after looking (once more) into wp-content/plugins/footnotes/class/template.php.

    But fortunately your changes won’t get overwritten if the custom template is stored in wp-content/plugins/footnotes-custom/templates/public/reference-container.html.

    The container collapsing on clicking its heading even if it’s expanded by default is only since v2.5.1, 15 weeks ago, when noticing that a custom template without the button was used in collapsed-by-default mode and I was unable to revert the expansion.

    As you report that hiding the button is ineffective when the label is used elsewhere, I now see that when adding the h2..h6 options for the label element (that initially was paragraph level only), I should have added also a dedicated template for the expanded-by-default mode.

    My apologies for missing out on so many fixes.

    Edit: Glad to see that you already found the solution.

    • This reply was modified 2 years, 11 months ago by pewgeuges.
    • This reply was modified 2 years, 11 months ago by pewgeuges.
    • This reply was modified 2 years, 11 months ago by pewgeuges.
    Thread Starter saskiawater

    (@saskiawater)

    Thank you. I’m not skilled enough to help you with development but hopefully I could help you find the bug and contribute as user.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Deactivate the collapsing functionality’ is closed to new replies.