The BoardMod Project
 The Project | News | Downloads | Mods | FAQ | Templates | Chat | Forum
BoardMod Support Forum
[ Home | Help | Search | Login | Register ]  

20.06.13 at 10:07:44, Welcome, Guest. Please Login or Register

Choose Language:
Pages: 1 2 3 4 
Spoiler Tag V1.5 for YaBB 2.4 (Read 11075 times)
Derek Barnstorm
Hacker God
*****
Offline

Warwickshire, United Kingdom
Posts: 1114



Reply #15 - 07.05.10 at 19:37:54  
Valtiel wrote on 07.05.10 at 16:53:52:
Thanks, used parts of your mod for my old YaBB - our spoiler mod was a little buggy, yours is very nice Wink . Oh, Chrome doesn't seem to care about the CSS style, Firefox, IE and Opera work well.

Okay, thanks!

I'll have to check it out in Chrome and try to get it fixed in the future.

It's not actually XHTML valid either - I keep meaning to come back to this one and giving it a rewrite - I'll try to get it done in the next update...
« Last Edit: 07.05.10 at 19:56:33 by Derek Barnstorm »  
IP Logged
 
Valtiel
Hacker God
*****
Offline

, Bayern, Germany
Posts: 873



Reply #16 - 10.05.10 at 16:27:05  
Hm, we have a problem with the tag. Some spoilers can't be opened. It seems to be totally randomly. For example on one page all spoiler buttons work, on the next only the first one. Or the first three work and the others don't. Any idea?

[Edit]:
Problem seems to appear only with Firefox.
« Last Edit: 10.05.10 at 18:22:37 by Valtiel »  
IP Logged
 

Proud copy & paste coder Grin
Admin @ Silent Hill Forum
Derek Barnstorm
Hacker God
*****
Offline

Warwickshire, United Kingdom
Posts: 1114



Reply #17 - 10.05.10 at 20:02:45  
Err, I'm not too sure why that is happening, sorry. I've just been testing and can't get it to act like you describe.

Are there any errors on the page? Can you give me a link to a thread where it is happening - you can PM it to me if you don't want to post links up...
 
IP Logged
 
Valtiel
Hacker God
*****
Offline

, Bayern, Germany
Posts: 873



Reply #18 - 10.05.10 at 20:20:27  
I can.

Here it doesn't work

On the next page they work

But you have to test with Firefox, don't forget Wink

WTF... now the one in the first link works. As I said... purely random.

And now it doesn't work again.
 
IP Logged
 

Proud copy & paste coder Grin
Admin @ Silent Hill Forum
Derek Barnstorm
Hacker God
*****
Offline

Warwickshire, United Kingdom
Posts: 1114



Reply #19 - 10.05.10 at 21:12:03  
Strange... I've just clicked on those links quite a few times in FireFox 3.6.3 on both my PC and Mac, and the spoiler worked every time. I really don't know what to suggest at the minute... sorry!

Have any of your members been noticing it too, or is it just you?

I want to get another Mod finished over the next few days, but if you can give me a little time I'll try to get this working in a better way and hopefully that will fix things.

Sorry again if that's not much help right now, but I will come back to it...
 
IP Logged
 
Jeff
Moderator
*****
Offline

, Netherlands
Posts: 2552



Reply #20 - 10.05.10 at 21:52:42  
Works for me too in Firefox 3.6.3. Does they clear the cache or hold STRG (CTRL) + F5 Button to refresh the site? Wink
 
IP Logged
 

greetings
Jeff
Valtiel
Hacker God
*****
Offline

, Bayern, Germany
Posts: 873



Reply #21 - 11.05.10 at 16:37:48  
@ Derek:
My whole team has the errors, too - but just like me only with Firefox.

@ Jeff:
Yes, that's not the reason Smiley
 
IP Logged
 

Proud copy & paste coder Grin
Admin @ Silent Hill Forum
Derek Barnstorm
Hacker God
*****
Offline

Warwickshire, United Kingdom
Posts: 1114



Reply #22 - 11.05.10 at 17:04:36  
Okay, yeah... It's just happened to me once too.

I haven't got a simple fix right now I'm afraid, but I'll try to sort it out once I've finished something else I'm working on...
 
IP Logged
 
Valtiel
Hacker God
*****
Offline

, Bayern, Germany
Posts: 873



Reply #23 - 11.05.10 at 17:10:27  
It can only be a problem with the JavaScript code in YaBBC.pl. Unfortunately I don't really understand JavaScript. Did you write that code by yourself, or did you take it from some website oder something?
 
IP Logged
 

Proud copy & paste coder Grin
Admin @ Silent Hill Forum
Derek Barnstorm
Hacker God
*****
Offline

Warwickshire, United Kingdom
Posts: 1114



Reply #24 - 11.05.10 at 22:05:57  
I'm afraid I didn't write the JS from scratch, no (that's one reason why I wanted to change it). I looked up the best way of doing a spoiler a couple of years ago, and this seemed the most common and reliable way - this method actually seems to be quite widely used.

I still have no idea why it is happening though and I can't get it to happen on my test board. I can only think that it's playing up with another division or a bit of javascript on your page.

Can you try this (without modifying it) - Just replace yours with this from the first to last division:

Code:
<div class="message"><div><b>$spoiler_txt{'01'}:</b><input type="button" class="button" value="$spoiler_txt{'02'}" onclick="if (this.parentNode.parentNode.getElementsByTagName('div')[1].getElementsByTagName('div')[0].style.display != '') { this.parentNode.parentNode.getElementsByTagName('div')[1].getElementsByTagName('div')[0].style.display = ''; this.value = '$spoiler_txt{'03'}'; } else { this.parentNode.parentNode.getElementsByTagName('div')[1].getElementsByTagName('div')[0].style.display = 'none'; this.value = '$spoiler_txt{'02'}'; }" /></div><div class="spoiler"><div style="display: none;">$1</div></div></div> 


I'm not really hopeful that it will work though, all I've really done is make it xhtml valid.
 
IP Logged
 
Valtiel
Hacker God
*****
Offline

, Bayern, Germany
Posts: 873



Reply #25 - 12.05.10 at 16:46:27  
Sorry, doesn't change anything. It really may be that the JavaScript interferes with some other JavaScript on my forum, but why randomly? The used JavaScripts are all loaded permanently.

I deactivated all other JavaScripts on my forum, but the error remains. Seems it has nothing to do with other JavaScripts.
« Last Edit: 12.05.10 at 17:08:54 by Valtiel »  
IP Logged
 

Proud copy & paste coder Grin
Admin @ Silent Hill Forum
Derek Barnstorm
Hacker God
*****
Offline

Warwickshire, United Kingdom
Posts: 1114



Reply #26 - 12.05.10 at 18:50:47  
Sorry, I have no idea. This is the error in FireFox:

Quote:
Error: this.parentNode.parentNode.getElementsByTagName("div")[1] is undefined
Source File: http://www.diplompsychopath.de/cgi-bin/yabb3/YaBB.pl?board=finalfantasy;action=d...
Line: 1

So I'm thinking it has to do with the doctype declaration on your page (though I can't recreate it).

Undecided
 
IP Logged
 
Valtiel
Hacker God
*****
Offline

, Bayern, Germany
Posts: 873



Reply #27 - 12.05.10 at 19:13:11  
Where do you get this error? My firefox doesn't show any error.
 
IP Logged
 

Proud copy & paste coder Grin
Admin @ Silent Hill Forum
Derek Barnstorm
Hacker God
*****
Offline

Warwickshire, United Kingdom
Posts: 1114



Reply #28 - 12.05.10 at 19:19:38  
Tools => Error Console
 
IP Logged
 
Valtiel
Hacker God
*****
Offline

, Bayern, Germany
Posts: 873



Reply #29 - 12.05.10 at 19:22:13  
Yes, I see... hm. My doctype is

Code:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> 



other's don't seem to work with YaBB 1.
 
IP Logged
 

Proud copy & paste coder Grin
Admin @ Silent Hill Forum
Pages: 1 2 3 4 
© 2000-2012 by - All rights reserved.

Project website hosting proudly sponsored and provided by UK2 Hosting
 The Project | News | Downloads | Mods | FAQ | Templates | Chat | Forum