Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

plugin clashes with Antispam plugin #11

Open
skinofthesoul opened this issue Apr 18, 2023 · 6 comments
Open

plugin clashes with Antispam plugin #11

skinofthesoul opened this issue Apr 18, 2023 · 6 comments
Assignees
Labels
bug Something isn't working

Comments

@skinofthesoul
Copy link

Hello,

first off, I love this plugin! Super easy to set up, and makes really nice galleries. The only problem I have so far is that it clashes with my Antispam plugin. Somehow Photoswipe eats up the end tags of the javascript mailto anchors generated by Antispam, resulting in open links all over a page.

I haven't had time to dig deeper with this yet, but I have noticed that this also happens on pages where there isn't even a Photoswipe gallery. So the plugin must be doing something on every page that results in missing tags – maybe you can tell what's happening right off the bat?

Would be great if this could be resolved – I'm using Antispam in all my projects and I would love to add Photoswipe as a staple ingredient as well!

@Karmalakas
Copy link
Owner

This sounds really strange, because output is not manipulated in any way if there's no Photoswipe in any of the templates on the page 😕 I'll try to look into it maybe during the weekend (but no promise)

@hughbris
Copy link
Contributor

I think this might be related, so I'll leave the comment here. I am also short of time to dig deeper right now, sorry.

I just noticed this plugin is not loading JS or CSS (so isn't working) on a production site only. In staging and dev, it worked beautifully (it really is a great plugin!).

So I looked at the differences and then disabled my Plausible plugin on prod. Photoswipe worked again. Luckily this client has shown no interest in metrics so it's mainly for me. I did test Plausible on staging but then turned it off. I guess I never tested the two plugins together on staging.

From a quick look, the Plausible plugin seems to use DOM injection in a similar way to this plugin. Hopefully that is a clue and hopefully the solution is simple. I'm happy to look into it if I remember and have time.

@Karmalakas
Copy link
Owner

I'm really sorry for dragging for so long, but I want to make use of good weather as much as possible, so I haven't been doing any work on my personal projects for a while now. Also have lots of other a bit more important stuff queued up already 😞

@hughbris
Copy link
Contributor

After a long journey, my issue seems unrelated to this one. It is also not related to the Plausible plugin. It was modular caching (#1). This explains why I only noticed the error on production. I thought it was Plausible because the photoswipe worked when I uninstalled it. However, when gallery pages are refreshed, the photoswipe doesn't load. Took me a while to notice that :)

It's only because you linked to #1 from #3 that I saw this issue. Normally I search issues and have to manually remove the annoying Github default of open issues only. For some reason did not do that this time.

I also noticed my leaflet map module (using Map Marker Leaflet) required this fix for production too.

Thank you, enjoy the sunshine @Karmalakas, and sorry for hijacking your issue thread @skinofthesoul.

@Karmalakas
Copy link
Owner

@skinofthesoul, is this still an issue? Or maybe you've figured it out by any chance? Now that weather is usually not good and cold, I'll spend more time on my projects until spring. Should I still dig into this? 🙂

@skinofthesoul
Copy link
Author

Well. I didn't have the time to go digging around in the code, so I resorted to using a different plugin. ¯_(ツ)_/¯ So the problem still exists, but I don't have to deal with it right now… I'd say this is one of the things that is likely to come back to bite you another time, but right now there's no pressure to fix it. ;-)

@Karmalakas Karmalakas self-assigned this Dec 28, 2023
@Karmalakas Karmalakas added the bug Something isn't working label Dec 28, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants