vForums Support Banner


Visit Base Classics - Gaming Chairs

 

Welcome Guest! Please Login or Register
vForums Support :: Programming & Coding :: Code Requests & Support :: Simple Guild List code - View Topic
Topic Rating: *****
Printable View
Aiken
Full Member
***

[Avatar]

Posts: 333
Status: Offline
Gender: Male
Location: In a very lonely place, the domain of despair
Age: 31
Joined:  
Reputation: 12%  


pmtwitterskypemsnyahooxfire
Simple Guild List code (24th Feb 10 at 4:57pm UTC)
Code:
 
  1. <script>
  2.  
  3. function GuildListing(Page){
  4.  
  5. GuildPages = Math.ceil((GuildList.length + 1)/10);
  6.  
  7. var GuildStart = (GuildPage * 10) - 10
  8. var GuildEnd = GuildStart + 10
  9.  
  10. var Guildpost = '<table class="border" width="100%">\n<tr height="20">\n<td class="title1" colspan="2">Guild List - Page ' + Page + '</td>\n</tr>\n';
  11.  
  12. for(i=GuildStart;i<=GuildEnd;i++){
  13.  
  14. if(i%2 == 0){
  15.  
  16. GuildPost += '<tr height="30">\n';
  17.  
  18. }
  19.  
  20. if(GuildList[i]){
  21.  
  22. GuildPost += '<td class="window1" width="50%">' + GuildList[i][0] + '</td>\n';
  23.  
  24. } else {
  25.  
  26. GuildPost += '<td class="window2" width="50%"> </td>\n';
  27.  
  28. }
  29.  
  30. if(i%2 == 1){
  31.  
  32. GuildPost += '</tr>\n';
  33.  
  34. }
  35.  
  36. }
  37.  
  38. GuildPost += '<tr height="20">\n<td class="title2" colspan="2">Close Window</td>\n</tr>\n</table>\n';
  39.  
  40. return GuildPost;
  41.  
  42. }
  43.  
  44. </script>
  45.  
 


There is a variable called GuildList which is a multidimensional array

vF forums:
Perfect World RP
BLEACH Universe - Under Construction / Testing Phase
Xen Qarna RP - Stage I
Vyren Entar Battle Network RP - Under Construction / Maintenance Mode Enabled
the Final Anime Hideout
Michael
Moderator
*****

[Avatar]
Recoding the future

Posts: 4,043
Status: Offline
Gender: Male
Location: UK
Joined:  

Additional Groups:
Coding Team
***


Reputation: 58%  


pmtwittervForum
Re: Simple Guild List code (27th Feb 10 at 7:57am UTC)
Is it not working or something? You've simply posted a code and not stated what you want us to do! {Unsure}
Aiken
Full Member
***

[Avatar]

Posts: 333
Status: Offline
Gender: Male
Location: In a very lonely place, the domain of despair
Age: 31
Joined:  
Reputation: 12%  


pmtwitterskypemsnyahooxfire
Re: Simple Guild List code (27th Feb 10 at 10:00am UTC)
I used document.write(GuildListing(1)); but nothing shows up

vF forums:
Perfect World RP
BLEACH Universe - Under Construction / Testing Phase
Xen Qarna RP - Stage I
Vyren Entar Battle Network RP - Under Construction / Maintenance Mode Enabled
the Final Anime Hideout
Michael
Moderator
*****

[Avatar]
Recoding the future

Posts: 4,043
Status: Offline
Gender: Male
Location: UK
Joined:  

Additional Groups:
Coding Team
***


Reputation: 58%  


pmtwittervForum
Re: Simple Guild List code (27th Feb 10 at 10:21am UTC)
Just from reading it ...

GuildList - Not defined anywhere


That's all I can see that would be the problem! {Smile}
Aiken
Full Member
***

[Avatar]

Posts: 333
Status: Offline
Gender: Male
Location: In a very lonely place, the domain of despair
Age: 31
Joined:  
Reputation: 12%  


pmtwitterskypemsnyahooxfire
Re: Simple Guild List code (27th Feb 10 at 10:41am UTC)
It is defined, I just didn't post it

vF forums:
Perfect World RP
BLEACH Universe - Under Construction / Testing Phase
Xen Qarna RP - Stage I
Vyren Entar Battle Network RP - Under Construction / Maintenance Mode Enabled
the Final Anime Hideout
Michael
Moderator
*****

[Avatar]
Recoding the future

Posts: 4,043
Status: Offline
Gender: Male
Location: UK
Joined:  

Additional Groups:
Coding Team
***


Reputation: 58%  


pmtwittervForum
Re: Simple Guild List code (27th Feb 10 at 11:10am UTC)
Have you got somewhere where this whole code is in use?
 Printable View

All times are GMT+0 :: The current time is 2:46am
Page generated in 0.2719 seconds
This Forum is Powered By vForums (v2.4)
Create a Forum for Free | Find Forums