dynastygal
Not New Member
[Sj1:0]
Posts: 23
dynastygal said 0 great things
|
Post by dynastygal on May 16, 2009 10:54:20 GMT -8
Hmmm, on my test board under newest member it shows the latest event, however it doesn't have anything like 'events' written above it...so it's not obvious what it is...how do I change it so it does have events above it so people know what that is? psrvtest.proboards.com/index.cgi
|
|
|
Post by Wormopolis on May 16, 2009 14:59:08 GMT -8
I dont see any events over in your side board...
|
|
dynastygal
Not New Member
[Sj1:0]
Posts: 23
dynastygal said 0 great things
|
Post by dynastygal on May 18, 2009 0:35:40 GMT -8
It's "dfsfdfds" - just a test title...I'll change it to make it more obvious... (changed it to event test)
|
|
|
Post by Wormopolis on May 18, 2009 3:59:00 GMT -8
I see what is happening. Keep an eye on this topic because I have to write in a bug fix for that. its replacing the "users online" with events.
|
|
|
Post by Wormopolis on May 19, 2009 3:03:23 GMT -8
I started on this and then fell asleep.. its like tankball all over again!
I should be able to finish this up tomorrow.
then I can get started on the skinview project...
|
|
|
Post by Wormopolis on May 19, 2009 5:24:31 GMT -8
That should handle events and birthdays now.
Keep in mind it just takes the information, not any of the titles or header cells. If you are moving things like events to another cell, its advisable to put your own Header above the destination to label that the following data is a list of events.
|
|
dynastygal
Not New Member
[Sj1:0]
Posts: 23
dynastygal said 0 great things
|
Post by dynastygal on May 19, 2009 7:36:25 GMT -8
Since I had to recopy the entire code...
it's gone back to the original...
How do I put it back to font size 2?
|
|
|
Post by Wormopolis on May 19, 2009 17:15:51 GMT -8
I forgot we made that change. You should be able to add back in the same line after like you did before. In fact, immediately after ANY line that looks like:
extractN=blah blah
if you put right after it:
extractN=extractN.replace(/size=\"1\"/i,"size='2' ");
where N is 1 through 6.
if that isnt clear I can repost the code with changes for you. those internal font tags like to do what they want and you have to force them to be bigger.
|
|
dynastygal
Not New Member
[Sj1:0]
Posts: 23
dynastygal said 0 great things
|
Post by dynastygal on May 19, 2009 18:05:02 GMT -8
Yep, I'm kinda lost XD
This is my code:
<script type="text/javascript"> <!-- // Clone Info Center pieces into placeable DIVs v1.2 // By Wormopolis // [url]wormocodes.proboards.com[/url] var hideOriginalInfoCenter=true; // set to true to hide, false to leave there
tds=document.getElementsByTagName('td'); dest1=document.getElementById("BOX1div"); //topics/posts/last topic/10 recent posts dest2=document.getElementById("BOX2div"); //members/newest member/personal messages dest3=document.getElementById("BOX3div"); //users online dest4=document.getElementById("BOX4div"); //users 24 hours dest5=document.getElementById("BOX5div"); //Events dest6=document.getElementById("BOX6div"); //Birthdays extract1=extract2=extract3=extract4=extract5=extract6=""; for (n=tds.length-1; n>0; n--) { if (tds[n].colSpan==2 && tds[n].className=="catbg" && tds[n].innerHTML.match(/forum statistics/i)) { extract1=tds[n].parentNode.nextSibling.firstChild.nextSibling.getElementsByTagName('td')[0].innerHTML; tmp=extract1.split('<br>'); tmp[2]=""; extract1=tmp.join('<br>'); extract2=tds[n].parentNode.nextSibling.firstChild.nextSibling.getElementsByTagName('td')[1].innerHTML; tmp=extract2.split('<br>'); if (tmp.length>2) tmp[2]=""; extract2=tmp.join('<br>'); // those 2 are static. for (rws=tds[n].parentNode.parentNode.getElementsByTagName('tr'), i=0; i<rws.length; i++) { if (rws[i].firstChild.className.match(/catbg/) && rws[i].firstChild.innerHTML.match(/events this month/i)) { extract5=rws[i].nextSibling.firstChild.nextSibling.firstChild.firstChild.firstChild.innerHTML; } if (rws[i].firstChild.className.match(/catbg/) && rws[i].firstChild.innerHTML.match(/users online/i)) { extract3=rws[i].nextSibling.firstChild.nextSibling.innerHTML; } if (rws[i].firstChild.className.match(/catbg/) && rws[i].firstChild.innerHTML.match(/active users/i)) { extract4=rws[i].nextSibling.firstChild.nextSibling.innerHTML; } if (rws[i].firstChild.className.match(/catbg/) && rws[i].firstChild.innerHTML.match(/Today's Birthdays/i)) { extract6=rws[i].nextSibling.firstChild.nextSibling.firstChild.firstChild.firstChild.innerHTML; }
} if (hideOriginalInfoCenter) tds[n].parentNode.parentNode.parentNode.parentNode.parentNode.style.display="none"; if (dest1) dest1.innerHTML=extract1; if (dest2) dest2.innerHTML=extract2; if (dest3) dest3.innerHTML=extract3; if (dest4) dest4.innerHTML=extract4; if (dest5) dest5.innerHTML=extract5; if (dest6) dest6.innerHTML=extract6; document.getElementById("ICDTable").style.display=""; break; } } //--> </script>
|
|
|
Post by Wormopolis on May 19, 2009 18:12:39 GMT -8
this should work: <script type="text/javascript"> <!-- // Clone Info Center pieces into placeable DIVs v1.2 // By Wormopolis // wormocodes.proboards.comvar hideOriginalInfoCenter=true; // set to true to hide, false to leave there tds=document.getElementsByTagName('td'); dest1=document.getElementById("BOX1div"); //topics/posts/last topic/10 recent posts dest2=document.getElementById("BOX2div"); //members/newest member/personal messages dest3=document.getElementById("BOX3div"); //users online dest4=document.getElementById("BOX4div"); //users 24 hours dest5=document.getElementById("BOX5div"); //Events dest6=document.getElementById("BOX6div"); //Birthdays extract1=extract2=extract3=extract4=extract5=extract6=""; for (n=tds.length-1; n>0; n--) { if (tds[n].colSpan==2 && tds[n].className=="catbg" && tds[n].innerHTML.match(/forum statistics/i)) { extract1=tds[n].parentNode.nextSibling.firstChild.nextSibling.getElementsByTagName('td')[0].innerHTML; tmp=extract1.split('<br>'); tmp[2]=""; extract1=tmp.join('<br>'); extract1=extract1.replace(/size=\"1\"/i,"size='2' "); extract2=tds[n].parentNode.nextSibling.firstChild.nextSibling.getElementsByTagName('td')[1].innerHTML; tmp=extract2.split('<br>'); if (tmp.length>2) tmp[2]=""; extract2=tmp.join('<br>'); extract2=extract2.replace(/size=\"1\"/i,"size='2' "); // those 2 are static. for (rws=tds[n].parentNode.parentNode.getElementsByTagName('tr'), i=0; i<rws.length; i++) { if (rws .firstChild.className.match(/catbg/) && rws.firstChild.innerHTML.match(/events this month/i)) { extract5=rws.nextSibling.firstChild.nextSibling.firstChild.firstChild.firstChild.innerHTML; extract5=extract5.replace(/size=\"1\"/i,"size='2' ");
} if (rws.firstChild.className.match(/catbg/) && rws.firstChild.innerHTML.match(/users online/i)) { extract3=rws.nextSibling.firstChild.nextSibling.innerHTML; extract3=extract3.replace(/size=\"1\"/i,"size='2' "); } if (rws.firstChild.className.match(/catbg/) && rws.firstChild.innerHTML.match(/active users/i)) { extract4=rws.nextSibling.firstChild.nextSibling.innerHTML; extract4=extract4.replace(/size=\"1\"/i,"size='2' "); } if (rws.firstChild.className.match(/catbg/) && rws.firstChild.innerHTML.match(/Today's Birthdays/i)) { extract6=rws.nextSibling.firstChild.nextSibling.firstChild.firstChild.firstChild.innerHTML; extract6=extract6.replace(/size=\"1\"/i,"size='2' "); }
} if (hideOriginalInfoCenter) tds[n].parentNode.parentNode.parentNode.parentNode.parentNode.style.display="none"; if (dest1) dest1.innerHTML=extract1; if (dest2) dest2.innerHTML=extract2; if (dest3) dest3.innerHTML=extract3; if (dest4) dest4.innerHTML=extract4; if (dest5) dest5.innerHTML=extract5; if (dest6) dest6.innerHTML=extract6; document.getElementById("ICDTable").style.display=""; break; } } //--> </script>
|
|
dynastygal
Not New Member
[Sj1:0]
Posts: 23
dynastygal said 0 great things
|
Post by dynastygal on May 19, 2009 18:22:43 GMT -8
That did it, thanks
|
|
|
Post by Wormopolis on May 19, 2009 19:45:00 GMT -8
Site looks great!
|
|
dynastygal
Not New Member
[Sj1:0]
Posts: 23
dynastygal said 0 great things
|
Post by dynastygal on May 21, 2009 3:34:30 GMT -8
Thanks, lol, although that's my test site. It's now fully working on www.psrv.co.uk/ however I was wondering if it is possible to add a line like "A total of # Users Logged On Today" to grab the stats (kinda) from last 24 hrs... So say if 24 people logged onto psrv that day, it would say: "A total of 24 users have logged on today." underneath "1 Staff Member, 1 Member, 2 Guests. Most users online was 267, Jun 16, 2008, 11:36am User Name, User Name"
|
|
|
Post by Wormopolis on May 21, 2009 22:21:42 GMT -8
I will have to play around with some RegExp, but it can be done.
|
|
dynastygal
Not New Member
[Sj1:0]
Posts: 23
dynastygal said 0 great things
|
Post by dynastygal on May 23, 2009 10:01:34 GMT -8
Mkay.
|
|