LeagueCMS
competition management for DragonFly CMS

Customizing

The public support form for mComp, online gaming Competition Management Software
Reply to topicReply to topic Printer Friendly Page
Forum FAQSearchView unanswered posts

Customizing

Post Posted: Mon Apr 12, 2010 9:09 am

im doing some customizing of mcomp

on the details page for fixtures ive got it to pull up the streaming status of the server the match is been played on

however the problem is when the server is set to none

this my code

Code:
if (!$fixdata['saddr']) {;
  echo '<tr><td class="row1"><b>Streaming Status</b></td><td class="row2"><img src="http://www.punksbusted.com/psbsig/psbsig.php/server/'.$saddr.'.png" border="0">
</td></tr>';

just wondered if anyone can offer a solution?

squaddie
Regular
Regular
 

Customizing

Post Posted: Mon Apr 12, 2010 9:51 am

Is that the entire code, because it looks like you have a syntax error.

In this line :-

PHP:

if (!$fixdata['saddr']) {;

Is there really a semi-colon ";" immediately after the "{" ?

Also, is there a closing "}" after the "echo" statement or is there more ?

mark
Site Admin
Site Admin
 

Customizing

Post Posted: Mon Apr 12, 2010 11:42 am

think ive sorted it Mark - well in ladders anyway

deleted the Home/away server & it shows the first server in the server list

is there any that it can pull the home teams server from the list first, so when generating fixtures in a league it woul pick the home server

squaddie
Regular
Regular
 

Customizing

Post Posted: Mon Apr 12, 2010 7:06 pm

When selecting a server it sorts them by name, and includes servers that belong to either team or servers that don't belong to anyone (i.e. can be used by everyone). To sort them by home / away would take come extra code, but of course anything is possible.

The variable $fixdata['saddr'] contains the server the match is due to be played, or was played, on.

mark
Site Admin
Site Admin
 

Customizing

Post Posted: Mon Apr 12, 2010 7:46 pm

k m8 ill get back to ya

ive actually done quite a bit of hacking the script adding things but this has me stumped

as I said for ladders its really a problem as they choose their own server

but leagues when we do generate fixtures it puts a None server in the array even though their is only clans own servers in the server table in database

squaddie
Regular
Regular
 

Customizing

Post Posted: Mon Apr 12, 2010 8:14 pm

So basically when manually creating a fixture you'd like a list of servers with the home teams server(s) listed first, then the away teams? And when generating fixtures automatically assign the home teams (1st) server if they have one?

I'm sure I can do both, and it does actually makes sense.

What version of mComp are you using though, because the latest, v4.5.5 is a major code change from previous versions to include templating.

mark
Site Admin
Site Admin
 

Customizing

Post Posted: Tue Apr 13, 2010 1:06 am

yeh thats what I was thinking mark

& 4.5.5 is the version im running

squaddie
Regular
Regular
 

Customizing

Post Posted: Tue Apr 13, 2010 5:00 pm

Then I shall make it so Smile

Just give me a couple of days, rather busy at the mo' Very Happy

mark
Site Admin
Site Admin
 

Customizing

Post Posted: Tue Apr 13, 2010 7:55 pm

no rush m8

thx

squaddie
Regular
Regular
 

Re: Customizing

Post Posted: Wed Apr 14, 2010 11:46 am

OK, think I've done it (something came up today, left me with a bit of time).

Attached are some amended files, and ONLY the files that have changed so you can see which ones if you've made any amendments to these yourself. Please make sure you keep backups of the files you replace before using these.

I'd appreciate you feedback, they seem to work OK on my test data but I'd appreciate you testing them before I release them as part of the package.

Last edited by mark on Tue Jun 15, 2010 8:56 am; edited 1 time in total

mark
Site Admin
Site Admin
 

Customizing

Post Posted: Wed Apr 14, 2010 4:28 pm

thast working perfect mark

gereates the fixtures & picks the home team server as default

squaddie
Regular
Regular
 
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