Jump to content

Recommended Posts

Posted

Hey,

Just noticed that I had edited something on our roster and a pilot registered PAV079 Chris Odyssey and he is not in order... any ideas?

http://www.pashairvirtual.co.uk/index.php/Listing

the part I had edited

<td><?php
$fieldvalue = PilotData::GetFieldValue($pilot->pilotid, 'VATSIM ID');
if($fieldvalue != '1')
{
  echo '<a href="http://www.vataware.com/pilot.cfm?cid='.$fieldvalue.'" target="_blank"><center><img src="'.SITE_URL.'/images/vatsim.gif" alt="Vatsim ID" /></center></a>';
}
else
{
echo '<center><img src="/images/novat.png" width="20" height="18" border="0"/></center></a>';
}
?>
<?php
}
?>
</td>

  • Administrators
Posted

It is how the data is coming back from the database. You have probably deleted a pilot along the way and the datbase has repopulated that field with another line of data which puts it out of line. You can set how you want your pilots sorted in the local.config.php file.

/* For PILOTS_ORDER_BY use p.[column_name] [ASC/DESC] */
Config::Set('PILOTS_ORDER_BY', 'p.pilotid DESC');

Posted

It is how the data is coming back from the database. You have probably deleted a pilot along the way and the datbase has repopulated that field with another line of data which puts it out of line. You can set how you want your pilots sorted in the local.config.php file.

/* For PILOTS_ORDER_BY use p.[column_name] [ASC/DESC] */
Config::Set('PILOTS_ORDER_BY', 'p.pilotid DESC');

Thanks a lot sim pilot

Posted

SimPilot I had added that bit to the local.config and then optimized tables but still no luck.. also I had to change a pilot Id because he became staff and his pilot Id is PAV009 and it half way down the roster.

Thanks

  • Administrators
Posted

You must have a mis-spell somewhere or something, I have it set up the same axcat way and it is working. Double check the additional config lines and make sure it is not in your file twice and overriding itself.

  • Administrators
Posted

Without the files i have no idea.

The other thing you could do that would probably fix it is go into phpMyAdmin and go under the operations tab for the pilots table. Use the alter table order by: function and set it to pilotid ascending.

Posted

Without the files i have no idea.

The other thing you could do that would probably fix it is go into phpMyAdmin and go under the operations tab for the pilots table. Use the alter table order by: function and set it to pilotid ascending.

Ok, I'l try that now

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...