What happened to the Messenger Plus! forums on msghelp.net?
Shoutbox » MsgHelp Archive » Skype & Technology » Tech Talk » Javascript spoiler tag help (solved + added final code)

Pages: (3): « First « 1 2 [ 3 ] Last »
Javascript spoiler tag help (solved + added final code)
Author: Message:
-dt-
Scripting Contest Winner
*****

Avatar
;o

Posts: 1819
Reputation: 74
36 / Male / Flag
Joined: Mar 2004
RE: Javascript spoiler tag help (solved + added final code)
quote:
Originally posted by ShawnZ
BTW:

function getElementsByClassName(checkClassName) {
r = new array(document.elements.length);
for (i=0;i<document.getElementsByTagName('div').length;i++) {
if (document.elements[i].className == checkClassName) {
r[] = document.elements[i]
}
}
return r;
}

getElementsByClassName('spoiler') == an array of all the page elements with the class name spoiler, afaik
What happens if it has more than one class? :refuck:
[Image: dt2.0v2.png]      Happy Birthday, WDZ
03-02-2006 02:54 AM
Profile PM Web Find Quote Report
Pages: (3): « First « 1 2 [ 3 ] Last »
« Next Oldest Return to Top Next Newest »


Threaded Mode | Linear Mode
View a Printable Version
Send this Thread to a Friend
Subscribe | Add to Favorites
Rate This Thread:

Forum Jump:

Forum Rules:
You cannot post new threads
You cannot post replies
You cannot post attachments
You can edit your posts
HTML is Off
myCode is On
Smilies are On
[img] Code is On