vForums Support > Programming & Coding :: Database of Codes/Hacks/Mods :: > Lvl 2 Affiliate Table

Lvl 2 Affiliate Table - Posted By Michael (wrighty) on 2nd Apr 08 at 6:26pm
Second Affiliate table out of a series that will be arriving!

<script>
/*Lvl 2 Affiliate Table
Created By Wrighty
Don't: Rip, Repost or Claim!*/

var affiliates = [
["http://support.vforums.co.uk", "http://virtualforums.co.uk/images/home.gif"],
["http://support.vforums.co.uk", "http://virtualforums.co.uk/images/home.gif"],
["http://support.vforums.co.uk", "http://virtualforums.co.uk/images/home.gif"],
["http://support.vforums.co.uk", "http://virtualforums.co.uk/images/home.gif"]
];

document.write('<table border="0" cellSpacing="1" cellPadding="3" class="border" width="500px">');
document.write('<tr><td class="title1">' + document.title.split(/ -/)[0] + '\'s Affiliates');
document.write('</td></tr><tr><td class="window1">');

for(i=0;i<affiliates.length; i++){
    document.write('<a href="' + affiliates[i][0] + '"><img src="' + affiliates[i][1] + '" border="0"></a>');
}

document.write('</td></tr></table>');

</script>


Simply edit this part:

var affiliates = [
["http://support.vforums.co.uk", "http://virtualforums.co.uk/images/home.gif"],
["http://support.vforums.co.uk", "http://virtualforums.co.uk/images/home.gif"],
["http://support.vforums.co.uk", "http://virtualforums.co.uk/images/home.gif"],
["http://support.vforums.co.uk", "http://virtualforums.co.uk/images/home.gif"]
];


repeating the lines for more and more affiliates. Remember, there is no comma on the last line.

Place this code anywhere. Where it is placed, it will appear!

Re: Lvl 2 Affiliate Table - Posted By Entold (silentassassin) on 14th May 08 at 7:21pm
Wrighty, hi the <;/tr><tr> in this code makes the forum go wacky. If you remove it, its fine. Also when adding this code, it makes the forum go to the left and not stay centered.

Re: Lvl 2 Affiliate Table - Posted By Michael (wrighty) on 14th May 08 at 7:28pm
For some reason vF added that semi colon. Post in code support if there's a problem! {Smile}

Wasn't a problem when this was coded.

Re: Lvl 2 Affiliate Table - Posted By Marc (cr0w) on 14th May 08 at 7:33pm
 
For some reason vF added that semi colon. Post in code support if there's a problem! {Smile}

Wasn't a problem when this was coded.


Semicolon's there again. {Tongue Out}

Seems we needs a bug report posted.

Re: Lvl 2 Affiliate Table - Posted By ajay (ajay) on 14th May 08 at 7:34pm
There wasn't? I tried this code and it always happens to me. But when i use v1 it works fine! {Smile}

Re: Lvl 2 Affiliate Table - Posted By Michael (wrighty) on 14th May 08 at 7:35pm
v1 is nothing like v2.

Re: Lvl 2 Affiliate Table - Posted By ajay (ajay) on 14th May 08 at 7:38pm
I know! {Smile}

Re: Lvl 2 Affiliate Table - Posted By Nick (nickb) on 18th May 08 at 7:11am
Preview please {Tongue Out}

Re: Lvl 2 Affiliate Table - Posted By Alex Bailey (system) on 18th May 08 at 1:24pm
Does it actually take long to try it on a forum to try it yourself?

Re: Lvl 2 Affiliate Table - Posted By ashkir (ashkir) on 28th Jul 08 at 9:53pm
 
Preview please {Tongue Out}


http://wimg.co.uk/AYNj5p.gif

Re: Lvl 2 Affiliate Table - Posted By Michael (wrighty) on 28th Jul 08 at 9:56pm
Thank you Ash! {Smile}