• Resolved olivergesch

    (@olivergesch)


    My understanding is that the tooltip should show a “more” link whenever the glossary entry is longer than the limit configured in the settings. You should not be able to remove the “more” link without a pro version.

    Now, on my site, it is the other way around. I cannot figure out how to make the “more” link visible. I tried different tooltip styles and reduced the limit to a few characters to force the “more” link to show up but nothing worked.

    In addition, I am somehow able to switch the setting for “remove more link” to “on” even without a pro version. Not sure why, but it unfortunately also does not have any effect on the visibility of the “more” link.

    The “more” link does not show up on mobile as well and instead of showing the tooltip first, immediately after showing the tooltip I am redirected to the glossary page.

    I also tested your demo site on mobile and desktop and neither version does show the “more” link. On mobile, I am not even able to navigate to the glossary item after the tooltip appeared. Nowhere to click on it. See the following screenshots.
    Desktop: https://www.dropbox.com/s/1g901qzbl2d1zwr/desktop.png?dl=0
    Mobile: https://www.dropbox.com/s/horqtnitj3i9khe/mobile.PNG?dl=0

    Maybe I am understanding or doing something wrong? Please let me know.

    I would also be more than willing to buy the pro version if the “more” link would show up in that version and I am not immediately redirected on mobile on my page.

    Any idea what the issue might be?

    I am running WP 6.0.3 and Glossary 2.1.23.

    Best regards
    Oliver

    • This topic was modified 2 years, 4 months ago by olivergesch. Reason: Added version of plugin

    The page I need help with: [log in to see the link]

Viewing 11 replies - 1 through 11 (of 11 total)
  • Thread Starter olivergesch

    (@olivergesch)

    I also just noticed that the titles of blog posts are also being linked to glossary terms. Is there a way to prevent at least H1 blog post titles from being changed by the plugin? I don’t think the shortcode of the pro version to prevent a glossary item from being added will work in a blog post title.

    So how to read more link is generated is explained here https://docs.codeat.co/glossary/advanced-settings/#how-works-the-text-generation-inside-the-tooltips
    Also, there is no difference on mobile/desktop for the html generation and in our demo site the Read more link option is not enabled.

    Instead, about the glossary injection on header there could be various reasons and usually because the HTML is nested or a page builder alter the page. I don’t see in that link that issue on the header to investigate further.

    Thread Starter olivergesch

    (@olivergesch)

    Thank you for the quick reply! I read the page you linked and if I understand it correctly, the “more” link should show be visible based on the Glossary settings, nothing else. My settings are shown here and I deactivated the “remove more link” setting:
    https://www.dropbox.com/s/1g8htrb380rt6aq/settings.png?dl=0
    Any idea why it still does not show up?

    Concerning the problem with the blog post title showing glossary links, here is an example with the term “group”:
    https://reviving.work/ (scroll a bit down)
    I assume this is due to WP Bakery plugin and another type of blog post plugin might work better?

    1:

    About the read more I can confirm that the readmore is managed by the type of the link (I checked the code). If it is external, the read more shouldn’t be added.
    If you are using the external type and inserting an internal url the plugin is not able to understand that is internal. For this reason there is the URL picker for that.

    2:

    The page is generated with a visual composer and it is alter the way the plugin works. Basically is not able to understand what is going on and what html tag it is, probably it is executed multiple times. Did you tried to disable Glossary on the home page (in the backend of that page)?

    Thread Starter olivergesch

    (@olivergesch)

    1.
    I don’t think that is the problem. I am only trying to use internal links. I pretty much tried every combination I could think of already. When creating a new glossary entry “external” is pre-selected but the external text field is empty. I tried “internal” and kept the internal text field empty and I also tried setting the internal text field to the current term or to any other page (for testing). Doesn’t make a difference. There is never a “more” link in the popup.
    I checked WP debug, only shows one message:
    [26-Oct-2022 18:29:22 UTC] PHP Notice: Undefined index: rel in /home/wp/disk/wordpress/wp-content/plugins/glossary-by-codeat/frontend/Core/Type/LinkTooltip.php on line 49

    Could it be a false setting in the plugin configuration, invisible on the settings page, just false configured in the DB? Why I think that: for some reason, I can change the “remove more link from plugin” setting although I don’t have a pro license. Is there a way to reset the DB entries for this plugin after I delete the plugin? I already tried re-installing it but I assume it keeps the DB entries between installs?

    2. Yes, then there are no glossary links at all on the homepage. I hoped to get them just in the paragraph sections but this would not be a showstopper. Issue number 1 unfortunately is a showstopper for me.

    Thread Starter olivergesch

    (@olivergesch)

    1. Ok I don’t think it’s a DB issue. I can see “more_link”;s:2:”on”; showing up and vanishing in the table based on my setting of the checkbox in the glossary settings. So the button seems to work for me (for whatever reason without a license).

    Thread Starter olivergesch

    (@olivergesch)

    Meanwhile, I purchased the plugin and I think I found the issue in the code. This statement seems to be the issue:

    if (
    	empty( $this->parameters[ 'url' ] )
    	&& empty( $this->parameters[ 'type' ] )
    	|| 'internal' === $this->parameters[ 'type' ]
    	|| 'external' === $this->parameters[ 'type' ]
    	&& empty( $this->parameters[ 'url' ] )
    	) {
    	$this->parameters[ 'noreadmore' ] = true;
    }

    Some brackets would help with the resolution logic but I think this means (left to right resolution) that if the type is “internal” then “noreadmore” is always true and the “more” link will never show up. The only way to get a more link with this statement (to make it false) is to set the glossary item to “external” AND put in an external URL. Then the more link is visible.

    • This reply was modified 2 years, 4 months ago by olivergesch.

    There is a specific code that print to read more link and basically doesn’t add it if the link is external, if there is something that let’s working also on the free version the next release won’t have that code.
    The button it should be disabled but I will do a check also for that.
    Anyway after all those messages is not clear to me what is the issue as usually in this case for premium users we asks for the admin access to check the settings and we do a better investigation.

    Thread Starter olivergesch

    (@olivergesch)

    Well, I don’t quite understand the full intention of the code piece I posted above however it is the source of my issue. If I comment out the line with “internal” type it works as intended, including the setting for “remove more link”:

    if (
    	empty( $this->parameters[ 'url' ] )
    	&& empty( $this->parameters[ 'type' ] )
    	//|| 'internal' === $this->parameters[ 'type' ] // not required?
    	|| 'external' === $this->parameters[ 'type' ]
    	&& empty( $this->parameters[ 'url' ] )
    	) {
    	$this->parameters[ 'noreadmore' ] = true;
    }

    Is there a situation where you don’t want a “more” link to be visible at all when the internal type is set? I can’t think of any situation because the “more link” will either redirect to any internal page or to the glossary item if no internal page is selected. The plugin setting for removing the “more link” also still has an effect.

    I am fine with my local change for now but in my opinion, this behavior is a bug and should be corrected. There is no way to make the “more” link visible when the glossary item is set to type “internal”. Feel free to test that out in your instance.

    Do you want me to post this issue again in the commercial ticket system (https://support.codeat.co/) of the plugin? I have access to that now.

    • This reply was modified 2 years, 4 months ago by olivergesch.

    I missed your third post but now it’s more clear you have issues on not getting the Read more if the link is internal.
    That one indeed is an error as should check the URL if empty or not, also our unit test after that change reported that it is indeed an issue.

    The next minor release will have that fix. I think that I will do the release on monday to avoid troubles.

    Thread Starter olivergesch

    (@olivergesch)

    Ok great, then I will look forward to the next release. So far I am very happy with the pro version. It has exactly the amount of customization that I need. Other plugins were very overloaded with settings that just make them extremely cumbersome to configure.

    So I will close this thread, thanks for your help!

Viewing 11 replies - 1 through 11 (of 11 total)
  • The topic ‘“More” link missing in tooltip’ is closed to new replies.