Jump to content

Map of the last flights of the pilot


Rafael

Recommended Posts

Add to pilot_public_profile.tpl(It is in public_html / Core / Templates)

<?php
if(!$pireps)
{
echo '<p>Sorry No recent flights have been found</p></div>';
return;
}
$flights = PIREPData::getLastReports($userinfo->pilotid, '5');
$string = "";
foreach($flights as $flight)
{
$string = $string.$flight->depicao.'+-+'.$flight->arricao.',+';
}
?>
<p align="center"><strong>Pilots Recent Flights</strong><br /><img src="http://www.gcmap.com/map?P=<?php echo $string ?>&MS=bm&MR=240&MX=685x360&PM=pemr:star10:red%2b%22%25I%22:white&PC=blue" /><br />
Maps generated by the <a href="http://www.gcmap.com/">Great Circle Mapper</a> - copyright © <a href="http://www.kls2.com/~karl/">Karl L.Swartz</a></p>

Add to profile_main.tpl(It is in your Template!)

<?php

$flights = PIREPData::getLastReports($userinfo->pilotid, '5');
$string = "";
foreach($flights as $flight)
{
$string = $string.$flight->depicao.'+-+'.$flight->arricao.',+';
}
?>
<p align="center"><strong>Pilots Recent Flights</strong><br /><img src="http://www.gcmap.com/map?P=<?php echo $string ?>&MS=bm&MR=240&MX=685x360&PM=pemr:star10:red%2b%22%25I%22:white&PC=blue" /><br />
Maps generated by the <a href="http://www.gcmap.com/">Great Circle Mapper</a> - copyright © <a href="http://www.kls2.com/~karl/">Karl L.Swartz</a></p>

MYtiN.png

Link to comment
Share on other sites

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...