LeagueCMS
competition management for DragonFly CMS

Forum style tables

Forum for general discussion and stuff that doesn't go somewhere else
Reply to topicReply to topic Printer Friendly Page
Forum FAQSearchView unanswered posts

Forum style tables

Post Posted: Tue Feb 21, 2012 11:11 pm

Hey, just wondering about where and what to edit to have the layout behave like the forums where as by each post alternates its background/colour

I.E *sorry for bad mockup*

Instead%20of%20

shuy3n
Newbie
Newbie
 

Re: Forum style tables

Post Posted: Wed Feb 22, 2012 9:34 am

That specific template is /themes/YOURTHEME/template/Competition/formats/league.html. The individual lines look like this :-

Code:
<tr>
  <td class="{division.team.STYLE}">{division.team.NUM}</td>
  <td class="{division.team.STYLE}">{division.team.TEAM}</td>
  ....
</tr>

You could therefore replace class="{division.team.STYLE}" with class="mystyle" and define your own style definition, however this code is used for ALL lines in ALL divisions, there's no facility to use a different style for alternate divisions in the template, you'd need to hack the PHP code to do that, and re-hack that code each and every time you update the module.

Furthermore, when setting up the divisions you can specify how many teams get promoted or relegated. It doesn't actually promote or relegate because there is no link between seasons, but it uses jQuery UI classes to style the lines differently.

For example, suppose you have 8 teams in a division and you decide that the top 2 will be promoted and the bottom 2 relegated, it will use jQuery UI style definition ui-state-highlight for the first 2 rows and the last 2 rows, so they will be coloured differently from the middle 4 rows.

If you remove class="{division.team.STYLE}" from the template you would render this feature useless.

mark
Site Admin
Site Admin
 

Re: Forum style tables

Post Posted: Wed Feb 22, 2012 11:56 am

Ahhh that's cool, it was just something I was knocking around with in Photoshop and thought I'd ask Smile thanks for the reply

shuy3n
Newbie
Newbie
 
Page 1 of 1



You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You cannot download files in this forum