vForums Support > Programming & Coding :: Code Requests & Support :: > [F] Sub Board Splitter Code Please

[F] Sub Board Splitter Code Please - Posted By CåñåÐå™ (canada) on 17th Jun 08 at 5:05pm
A code to split the sub-boards (Put a space between each of the sub-board) so they are separated from each other. Thanks {Smile} .

Re: Sub Board Splitter Code Please - Posted By Marc (cr0w) on 18th Jun 08 at 1:54am
Would you like each board to have head/base images? {Smile}

Re: Sub Board Splitter Code Please - Posted By CåñåÐå™ (canada) on 18th Jun 08 at 2:27am
I would like to , would it make a differents that i have about 7 template/skins on the forum ?
If it does then don't worry about head/base image bro.

Or which way is better for you is fine with me. {Grin}

Thanks Marc.

Re: Sub Board Splitter Code Please - Posted By Marc (cr0w) on 18th Jun 08 at 2:29am
You seem to be forgetting that vForums comes built-in with separate headers/footers for separate skins. {Wink}

I'll get this to you tomorrow. {Smile}

Re: Sub Board Splitter Code Please - Posted By CåñåÐå™ (canada) on 18th Jun 08 at 2:38am
I didn't really, i just didn't know how you would do it {Grin} .

Thank you Marc .

Re: Sub Board Splitter Code Please - Posted By Michael (wrighty) on 18th Jun 08 at 8:36pm
try this! {Smile}

<script>
/*Split Sub-boards
Wrighty
No Repost, rip, or claiming!*/

if(location.href.match(/board/)){
    var a = get('tr','tag')
    var h = document.createElement('div');
    var s = document.createElement('div');
    s.style.height = '20px';
    var x;
    for(z = 0; z < a.length; z++){
        if(a[z].id.match(/board_/)){
            x = a[z].parentNode.parentNode;
            var t = document.createElement('table');
            with(t){
                cellSpacing = '1';
                cellPadding = '3';
                className = 'border';
                width = vf_width;
                align = 'center';
            }
            t.appendChild(a[z].cloneNode(true));
            h.appendChild(get('table','tag')[0].cloneNode(true));
            h.appendChild(t);
            h.appendChild(get('table','tag')[3].cloneNode(true));
            h.appendChild(s.cloneNode(true));
        }
    }
    x.parentNode.previousSibling.style.display = 'none';
    x.parentNode.nextSibling.style.display = 'none';
    x.parentNode.replaceChild(h, x);
}

</script>


Global Footers.

Probably will be bugs as I haven't got any head/base to test with! {Tongue Out}

Re: Sub Board Splitter Code Please - Posted By CåñåÐå™ (canada) on 18th Jun 08 at 10:51pm
Yeah there is one bug that i can see , the code is in the near top of the global footer. If you need to see what the sub-boards look like (i'm sorry but you'll have to login wrighty). But here are two screen shots, if it will help.

Image

Image

Re: Sub Board Splitter Code Please - Posted By Michael (wrighty) on 19th Jun 08 at 8:19am
Yes I know hwy, I'll get to a fix soon! {Smile}

Re: Sub Board Splitter Code Please - Posted By CåñåÐå™ (canada) on 19th Jun 08 at 9:40pm
Ok thanks Wrighty {Grin} .

Re: Sub Board Splitter Code Please - Posted By CåñåÐå™ (canada) on 21st Jun 08 at 1:35am
 
Yes I know hwy, I'll get to a fix soon! {Smile}
Any word on this Wrighty {Confused} .

Re: Sub Board Splitter Code Please - Posted By CåñåÐå™ (canada) on 23rd Jun 08 at 3:13am
I'm only doing this in case you forgot Wrighty {Grin} .

Re: Sub Board Splitter Code Please - Posted By Michael (wrighty) on 23rd Jun 08 at 8:41am
I did.... but I was very busy over the weekend.


Should be doing it tonight! {Smile}

Re: Sub Board Splitter Code Please - Posted By CåñåÐå™ (canada) on 23rd Jun 08 at 9:59am
Cool thanks bro {Smile} .

Re: Sub Board Splitter Code Please - Posted By Michael (wrighty) on 24th Jun 08 at 6:29pm
Recopy the code! {Smile}

Re: Sub Board Splitter Code Please - Posted By CåñåÐå™ (canada) on 24th Jun 08 at 7:53pm
Thank you Wrighty it works fine {Grin} , peace {Cool} .

Re: Sub Board Splitter Code Please - Posted By Michael (wrighty) on 24th Jun 08 at 7:56pm
{Grin}

Glad to help!