Server Help Forum Index Server Help
Community forums for Subgame, ASSS, and bots
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   StatisticsStatistics   RegisterRegister 
 ProfileProfile   Login to check your private messagesLogin to check your private messages   LoginLogin (SSL) 

Server Help | ASSS Wiki (0) | Shanky.com
Broken 'code' tags?

 
Post new topic   Reply to topic Printable version
 View previous topic  Newer-er Server Post :: Post Need to Commission a Graphic Artist/We...  View next topic  
Author Message
Samapico
No, these DO NOT look like penises, ok?


Joined: May 08 2003
Posts: 1252
Offline

PostPosted: Wed Jun 08, 2011 8:21 am   Post maybe stupid    Post subject: Broken 'code' tags? Reply to topic Reply with quote

On Chrome, the show/hide button that appears with code tags doesn't seem to work right... You click it once, it hides the code, but it also hides the "show/hide" link, so you can't show it back.
Is it just me?

Code: Show/Hide

blah

_________________
(Insert a bunch of dead links here)
Back to top
View users profile Send private message Add User to Ignore List
Cheese
Wow Cheese is so helpful!


Joined: Mar 18 2007
Posts: 1017
Offline

PostPosted: Wed Jun 08, 2011 4:13 pm   Post maybe stupid    Post subject: Reply to topic Reply with quote

works fine on ff
_________________
SSC Distension Owner
SSCU Trench Wars Developer
Back to top
View users profile Send private message Add User to Ignore List Visit posters website AIM Address
CypherJF
I gargle nitroglycerin


Gender:Gender:Male
Joined: Aug 14 2003
Posts: 2582
Location: USA
Offline

PostPosted: Wed Jun 08, 2011 6:41 pm   Post maybe stupid    Post subject: Reply to topic Reply with quote

Definitely broke with Chrome 12.0.742.91 w/ Win Vista.
_________________
Performance is often the art of cheating carefully. - James Gosling
Back to top
View users profile Send private message Add User to Ignore List
Maverick
broken record


Age:39
Gender:Gender:Male
Joined: Feb 26 2005
Posts: 1521
Location: The Netherlands
Offline

PostPosted: Thu Jun 09, 2011 11:50 am   Post maybe stupid    Post subject: Reply to topic Reply with quote

Broken on Chrome 11.0.696.77 on Windows 7 aswell.

I guess you just shouldn't hide code pieces when working in Chrome (or face it that you won't be able to show it again) tongue.gif
_________________
Nickname: Maverick (I changed my name!)
TWCore developer | Subspace statistics
Back to top
View users profile Send private message Add User to Ignore List Visit posters website
JoWie
Server Help Squatter


Gender:Gender:Male
Joined: Feb 25 2004
Posts: 215
Offline

PostPosted: Thu Jun 09, 2011 2:11 pm   Post maybe stupid    Post subject: Reply to topic Reply with quote

Looks like this is done on purpose. The javascript code does:
Code: Show/Hide

this.innerText = ""


"this" is the show/hide link.

Firefox does not implement this non-standard Internet Explorer attribute (it uses textContent which is in w3c DOM 3)
Back to top
View users profile Send private message Add User to Ignore List
Cheese
Wow Cheese is so helpful!


Joined: Mar 18 2007
Posts: 1017
Offline

PostPosted: Thu Jun 09, 2011 4:48 pm   Post maybe stupid    Post subject: Reply to topic Reply with quote

Code: Show/Hide

<div class="genmed" style="margin-bottom:2px">
<b>Code:</b>
<span class="gensmall">
<a onclick="if (this.parentNode.parentNode.parentNode.getElementsByTagName('div')[1].getElementsByTagName('div')[0].style.display != '') { this.parentNode.parentNode.parentNode.getElementsByTagName('div')[1].getElementsByTagName('div')[0].style.display = ''; this.innerText = ''; this.value = 'Hide'; } else { this.parentNode.parentNode.parentNode.getElementsByTagName('div')[1].getElementsByTagName('div')[0].style.display = 'none'; this.innerText = ''; this.value = 'Show'; }" style="width:45px;font-size:10px;margin:0px;padding:0px;" value="Hide" href="javascript:void(0)">Show/Hide</a>
</span>
</div>
Back to top
View users profile Send private message Add User to Ignore List Visit posters website AIM Address
Mine GO BOOM
Hunch Hunch
What What
Hunch Hunch<br>What What


Age:40
Gender:Gender:Male
Joined: Aug 01 2002
Posts: 3614
Location: Las Vegas
Offline

PostPosted: Mon Jun 13, 2011 6:09 am   Post maybe stupid    Post subject: Reply to topic Reply with quote

Thanks for letting me know, I'll fix it soon. I just threw in some random javascript a long time ago to add the hide/show because sometimes people would post their whole server.cfg file in their post and I liked to hide it when reading the thread.
Back to top
View users profile Send private message Add User to Ignore List Send email
Samapico
No, these DO NOT look like penises, ok?


Joined: May 08 2003
Posts: 1252
Offline

PostPosted: Mon Jun 13, 2011 5:22 pm   Post maybe stupid    Post subject: Reply to topic Reply with quote

I might be confusing this with another forum, but wasn't there something like a 'codebox' tag at some point? Like a code tag, but that includes a scrollbar and has a limited vertical size.
That could be handy for these kind of things
Back to top
View users profile Send private message Add User to Ignore List
Mine GO BOOM
Hunch Hunch
What What
Hunch Hunch<br>What What


Age:40
Gender:Gender:Male
Joined: Aug 01 2002
Posts: 3614
Location: Las Vegas
Offline

PostPosted: Mon Jun 13, 2011 6:51 pm   Post maybe stupid    Post subject: Reply to topic Reply with quote

That would be another site. If you happen to have handy javascript/css for them, I can upgrade random parts of the site however you guys would like.
Back to top
View users profile Send private message Add User to Ignore List Send email
Cheese
Wow Cheese is so helpful!


Joined: Mar 18 2007
Posts: 1017
Offline

PostPosted: Tue Jun 14, 2011 12:21 am   Post maybe stupid    Post subject: Reply to topic Reply with quote

could you install a black theme
this white one hurts my eyes icon_sad.gif
Back to top
View users profile Send private message Add User to Ignore List Visit posters website AIM Address
Guest



Offline

PostPosted: Sun Jun 19, 2011 5:02 pm   Post maybe stupid    Post subject: Re: Broken 'code' tags? Reply to topic Reply with quote

Samapico wrote:
On Chrome, the show/hide button that appears with code tags doesn't seem to work right... You click it once, it hides the code, but it also hides the "show/hide" link, so you can't show it back.
Is it just me?

Code: Show/Hide

blah


Yup same for me.
Back to top
Hakaku
Server Help Squatter


Joined: Apr 07 2006
Posts: 299
Location: Canada
Offline

PostPosted: Sun Jun 19, 2011 10:25 pm   Post maybe stupid    Post subject: Reply to topic Reply with quote

This is what the code is doing:
Code: Show/Hide
if (this.parentNode.parentNode.parentNode.getElementsByTagName('div')[1].getElementsByTagName('div')[0].style.display != '') {
   this.parentNode.parentNode.parentNode.getElementsByTagName('div')[1].getElementsByTagName('div')[0].style.display = '';
   this.innerText = '';
   this.value = 'Hide';
} else {
   this.parentNode.parentNode.parentNode.getElementsByTagName('div')[1].getElementsByTagName('div')[0].style.display = 'none';
   this.innerText = '';
   this.value = 'Show';
}

If you remove the two "this.innerText = '';", the code will work properly on Chrome (and any other WebKit derivative), as well as IE8 and probably Opera too. Firefox has no implementation of innerText, so it's simply ignored, hence why it seemingly works fine.

There's also an issue with the text editor buttons (i.e. [tag]...[/tag]), where they won't wrap tags around highlighted portions of text.
Back to top
View users profile Send private message Add User to Ignore List Send email
Mine GO BOOM
Hunch Hunch
What What
Hunch Hunch<br>What What


Age:40
Gender:Gender:Male
Joined: Aug 01 2002
Posts: 3614
Location: Las Vegas
Offline

PostPosted: Mon Jun 20, 2011 1:32 am   Post maybe stupid    Post subject: Reply to topic Reply with quote

Cheese wrote:
could you install a black theme

If it were even possible to switch themes with the hacks applied to the forums, I might. But it would be easier to just start fresh with brand new forums software, which sadly I don't have that much time to be able to do.

Hakaku wrote:
If you remove the two "this.innerText = '';", the code will work properly on Chrome (and any other WebKit derivative), as well as IE8 and probably Opera too. Firefox has no implementation of innerText, so it's simply ignored, hence why it seemingly works fine.

Thanks, made this modification. I assume IE6 breaks (what change won't?) but oh well.

Hakaku wrote:
There's also an issue with the text editor buttons (i.e. [tag]...[/tag]), where they won't wrap tags around highlighted portions of text.

That has been a bug for a long, long time. I never bothered to fix it, as I generally type the bbcode myself and no one else has complained before.
Back to top
View users profile Send private message Add User to Ignore List Send email
Display posts from previous:   
Post new topic   Reply to topic    Server Help Forum Index -> Trash Talk All times are GMT - 5 Hours
Page 1 of 1

 
Jump to:  
You can post new topics in this forum
You can reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum
View online users | View Statistics | View Ignored List


Software by php BB © php BB Group
Server Load: 669 page(s) served in previous 5 minutes.

phpBB Created this page in 0.520755 seconds : 38 queries executed (80.9%): GZIP compression disabled