• Resolved gatbye

    (@gatbye)


    Hello,
    Is it possible to choose the max number of internal links from my articles or pages to my glossary?
    I have a page speaking about softwares and the name of the software is linked too many times…
    Is it possible to delete some of the links or add one manually?
    Thanks a lot
    Gat

Viewing 5 replies - 1 through 5 (of 5 total)
  • Plugin Author Bastien Martinent

    (@bmartinent)

    You can use the filter “mywpglossary_override_tag_limit” to change how many time a single term can be change into a link.

    Something like this in your theme function.php file shoud do the trick.

    add_filter( 'mywpglossary_override_tag_limit', function(){ return 1; } , 0, 10 );

    This code prevent the plugin to change more than 1 iteration of each term.
    change 1 by -1 and it’s infinite, change it by 12 it will do 12 links.

    Thread Starter gatbye

    (@gatbye)

    Thanks Bastien.
    How to limit the number of internal page on a page?

    Is there a page where all the possibilities are explained?
    Thanks a lot

    Plugin Author Bastien Martinent

    (@bmartinent)

    You can’t limit the number of link per page, only per term.
    You cant also use this hook to replace link by mouseover popup

    “mywpglossary_insertion_style” change term display mode use ‘link’, ‘popin’ or ‘tippy_poppin’ ( ‘link’ by default )
    tippy popin are based on the js lib Tippy.js and ‘popin’ is a simple css only implementation.

    add_filter( 'mywpglossary_insertion_style', function(){ return 'tippy_poppin'; } , 0, 10 );

    Try it if you dont like to have to many internal link. But you need to know, long definitions are truncated and have a read more link into it.

    All usable hook and filter are in the plugin change log.
    Sorry for the lack of clear documentation there is all avalable filters, feel free to ask any question.

    “mywpglossary_matching” change term matching rules ( is_singular or in the in_the_loop and is_main_query and not in a glossary page by default )

    “mywpglossary_insertion_style” change term display mode use ‘link’, ‘popin’ or ‘tippy_poppin’ ( ‘link’ by default )

    “mywpglossary_override_term” change the terms data ( content, link, etc ) match in the current context

    “mywpglossary_exclude_tags” change parent tags ignored when searching for glossary terms ( hx and a by default )

    “mywpglossary_override_glossary_link” change the link generated for each terms “mywpglossary_display_term_content” change the content of each terms

    “mywpglossary_override_tag_limit” change the number of terms who can be displayed by pages ( -1 for infinite by default )

    “mywpglossary_tippy_theme” change the tippy theme

    “mywpglossary_glossary_term_limit” change the maximum display term in the glossary page ( 200 by default )

    “mywpglossary_glossary_term_archive” change the archive markup for the glossary page

    “mywpglossary_use_single” enable terms single, replace terms content into the block by links to the single

    ‘mywpglossary_alpha’ for index chars used by the glossay

    ‘mywpglossary_encapsulation_chars’ for accepted encapsulations chars

    ‘mywpglossary_term_transient_key’ for cache transient key

    ‘mywpglossary_term_transient_expiration’ for cache expiration time

    Thread Starter gatbye

    (@gatbye)

    Thanks for your answers.
    The plugin is great.
    I hope it will be possible to configure all these parameters directly in the wordpress admin panel. It would be even greater.
    Thanks for your work

    Plugin Author Bastien Martinent

    (@bmartinent)

    Thank you for interest and your feedback.

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Too many internal links’ is closed to new replies.