• Resolved vcb

    (@vcb)


    Hi there,

    I’m having issues using the plugin with PHP 8.0, 8.1, 8.2.
    Can you tell if there is any update available any time soon, or if there is a workaround available which I could implement in the meanwhile?

    Issue: When I switch from php7.4 to any php 8.x version the “hyperlinks” (/glossary/#testentry) which this plugin generates from any glossar-entry stops working.

    Thank you.

    • This topic was modified 1 year, 5 months ago by vcb.
Viewing 5 replies - 1 through 5 (of 5 total)
  • Plugin Author Bastien Martinent

    (@bmartinent)

    Thank you for you report, i will cheack that.

    Thread Starter vcb

    (@vcb)

    Thanks for the note Bastien. I’ve been digging a bit deeper; please see the following details:

    It looks like the data-url is set correct:
    class=”mywpglossary-term-def” data-title=”testglossar” data-url=”https://localhost/testpage/glossar/#testglossar

    Is there some js-script which forwards to the glossary term in case a user clicks on it?

    Another weird thing I don’t know what/why this happens. I’m getting the following console.log warnings, regardless the php version (7.4/8.x), Brave Browser:

    DevTools failed to load source map: Could not load content for https://unpkg.com/@popperjs/popper.min.js.map: HTTP error: status code 404, net::ERR_HTTP_RESPONSE_CODE_FAILURE
    DevTools failed to load source map: Could not load content for https://unpkg.com/tippy-bundle.umd.min.js.map: HTTP error: status code 404, net::ERR_HTTP_RESPONSE_CODE_FAILURE

    When I try to download the scripts manually it results in an error:
    Cannot find package @popperjs/popper.min.js.map@latest

    Can you tell what’s happening here?

    Thread Starter vcb

    (@vcb)

    Update: When I use php 7.4 the html glossar term uses/generates the following html link:
    I guess you kinda suspect where this error resides? Would you mind sharing it, this way I could have a look without spending too much time searching for the exact code-snippet within your source

    <a class="mywpglossary-definition" href="https://localhost/testpage/glossar/#testglossar">Testglossar</a>
    Plugin Author Bastien Martinent

    (@bmartinent)

    The way the plugin works, it hooks your content and detects your terms based on an array of all your published terms generated and updated when you add and update terms.

    when it finds a term it encapsulates them in a way it is easy for jquery to find them.

    The link or modal is generated in front in js based on the “mywpglossary_insertion_style” hook value ( ‘link’, ‘popin’ or ‘tippy_poppin ).
    What you see is the unmodified encapsulation of terms, and certainly a js errors prevent the script to do this work.

    I cannot promise anything, but maybe I can find some time to work on this this weekend.

    I really appreciate your enthusiasm for our plugin, Thank you.

    https://unpkg.com/ is a public repository of javascript library, it’s used when you don’t or can’t  want to redistribute lib in your production. Glossary load tippy ( https://atomiks.github.io/tippyjs/ ) a pretty nice popup lib. And tippy is based on popper( https://popper.js.org/ ) so it loads some files from it.

    A map file like this is used as a translation layer for the minified version of the script, it has only use in a development or debugging context. It seems from your logs and the link, the map file for the last version of popper is missing. Not a big deal as this url is reserved for the last stable version and will probably be fixed at some point.

    Best regard.

    Thread Starter vcb

    (@vcb)

    @bmartinent : I’ve been able to solve the issue. It’s been weird, but it had nothing todo with glossary plugin itself. Solved it by fixing my custom functions.php code. Ty for trying to help.

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘PHP 8.x manual fix available?’ is closed to new replies.