ncd200 Posted January 9, 2016 Report Share Posted January 9, 2016 Hello, I have created a new pilot list with Vatsim status banners in it. Only question is How do I let the system fills the Vatsim acount ID. The code I am using is : http://www.vatsimsig...tus/XXXXXXX.jpg I have created a custom profile field for your vatsim id, but now a script must insert the id on the xxxxxxxx. I have this code but it wont work. http://www.vatsimsigs.co.uk/status/( PilotData::GetFieldValue($pilot->pilotid, 'Vatsim ID') != "" ).jpg any help would be great. Rick Quote Link to comment Share on other sites More sharing options...
web541 Posted January 9, 2016 Report Share Posted January 9, 2016 Try this? <?php $fieldvalue = PilotData :: GetFieldValue ( $pilot -> pilotid , 'Vatsim ID' ); if( $fieldvalue != '' ) { echo '<img src="http://www.vatsimsigs.co.uk/status/'.$fieldvalue.'.jpg" />' ; } ?> Quote Link to comment Share on other sites More sharing options...
TennShadow Posted January 10, 2016 Report Share Posted January 10, 2016 This is the code I use in the pilot roster with just a link to vataware. <?php $fieldvalue = PilotData::GetFieldValue($pilot->pilotid, 'VATSIM ID'); if($fieldvalue != '') { echo '<a href="http://www.vataware.com/pilot/'.$fieldvalue.'" target="_blank"><img src="'.SITE_URL.'/images/vatsim.gif" alt="Vatsim ID" border="0" /></a>'; } ?> Quote Link to comment Share on other sites More sharing options...
ncd200 Posted January 10, 2016 Author Report Share Posted January 10, 2016 Thanks, it worked. Rick Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.