Show Position

User avatar
nzrunner
.
Posts: 90
Joined: Sun Sep 14, 2008 10:04 am
Joomleague version: 2.0.x
Location: Sydney, Australia
Contact:

Show Position

Postby nzrunner » Sun Sep 14, 2008 10:31 am

I am converting an existing Field Hockey related website from a PHP-Nuke CMS to a Joomla CMS and have installed JoomLeague as the sports module.  The technical details are as follows: -


I have the Random Player module running on the Home Page and it all looks fine.

What I would like to do is show the Players Position under their name.  So, in a vertical order, I would like to show: -

  • Image
  • Player Name
  • Player Position

Position is NOT one of the options available in the module parameters.  Does anyone have the code to enable me to show the Position?

Cheers
Joomla: 2.5.28
JoomLeague: 2.93.239
http://www.sydneymastershockey.com.au/competition

User avatar
julienV
Joomleague Core Developer
Joomleague Core Developer
Posts: 2016
Joined: Tue Jun 19, 2007 9:27 am
Location: France
Contact:

Re: Show Position

Postby julienV » Mon Sep 15, 2008 8:01 am

here it is.

[gelöscht durch Administrator]
You can hire me, I'm a Joomla professional freelance developer.
Please contact me at jlv@jlv-solutions.com
NO PM, please use email !

User avatar
nzrunner
.
Posts: 90
Joined: Sun Sep 14, 2008 10:04 am
Joomleague version: 2.0.x
Location: Sydney, Australia
Contact:

Re: Show Position

Postby nzrunner » Mon Sep 15, 2008 2:41 pm

Fantastic!

Just a couple of notes: -

  • I added the align = "center" statement to the div commands
  • If you choose only one project, the $query does not resolve correctly.  There appears to be something wrong with the WHERE clause.  As I am using all Projects it doesn't effect me, but it may effect someone else

Other than that, it works a treat, and is exactly what I was looking for.

Thanks for the help.
Joomla: 2.5.28
JoomLeague: 2.93.239
http://www.sydneymastershockey.com.au/competition

User avatar
julienV
Joomleague Core Developer
Joomleague Core Developer
Posts: 2016
Joined: Tue Jun 19, 2007 9:27 am
Location: France
Contact:

Re: Show Position

Postby julienV » Mon Sep 15, 2008 5:42 pm

i don't like to put the align information in the html, it should be controlled by css, it way more flexible.
You can hire me, I'm a Joomla professional freelance developer.
Please contact me at jlv@jlv-solutions.com
NO PM, please use email !

User avatar
nzrunner
.
Posts: 90
Joined: Sun Sep 14, 2008 10:04 am
Joomleague version: 2.0.x
Location: Sydney, Australia
Contact:

Re: Show Position

Postby nzrunner » Mon Sep 15, 2008 9:37 pm

OK.

I'm just teaching myself CSS formatting at the moment.

What should the code be, and which CSS file should it go into?
Joomla: 2.5.28
JoomLeague: 2.93.239
http://www.sydneymastershockey.com.au/competition

User avatar
nzrunner
.
Posts: 90
Joined: Sun Sep 14, 2008 10:04 am
Joomleague version: 2.0.x
Location: Sydney, Australia
Contact:

Re: Show Position

Postby nzrunner » Mon Sep 15, 2008 10:42 pm

That's OK, I think I've figured it out.  I added the following code into my template's CSS file: -

div.team{
text-align: center;
font-weight: bold;
}

div.project{
text-align: center;
font-weight: bold;
}

div.randomplayer{
text-align: center;
}

:thx:
Joomla: 2.5.28
JoomLeague: 2.93.239
http://www.sydneymastershockey.com.au/competition


Return to “mod_joomleague_random_player”

Who is online

Users browsing this forum: No registered users and 2 guests