ZooL Posted April 11, 2020 Share Posted April 11, 2020 // ==UserScript== // @name GalWorkAround // @namespace http://shaman-australis.com/ // @description Work around so can click img preview and gallery images // @author ZooL // @include http://*.shaman-australis.com/forum/index.php?/gallery* // @include https://*.shaman-australis.com/forum/index.php?/gallery* // @run-at document-end // @grant none // ==/UserScript== (function() { 'use strict'; var preimg; if(document.title=="A configuration or server error has occurred") { var elms = document.getElementsByTagName('link'); for (var i = 0; i < elms.length; i++) { if(elms.rel=="preload") { preimg=elms.href; } } var ctner = document.getElementById('ipsLayout_mainArea'); ctner.innerHTML="<a href='"+preimg+"'><img style='display:block;margin-left:auto;margin-right:auto;' src='"+preimg+"'></img></a>"; } })(); Just replaces the error message with a clickable intended image. Still can't comment and doesn't fix the DOM-url error that will causes first click in gallery to fail but at least you can see the images, so in gallery when screen goes dark on first click just click the X at top right then click again. Should work for both greasemonkey and tampermonkey. (haven't tested a super amount but seems to work but let me know if is error in there and will try fix) 3 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.