Jump to content

AlessandroCuba

Members
  • Posts

    14
  • Joined

  • Last visited

Posts posted by AlessandroCuba

  1. Small code showing the VATSIM weather in the template, random

    <div id="metar">

    <?php

    $sql = "SELECT ".TABLE_PREFIX."airports.id, ".TABLE_PREFIX."airports.icao as icao, ".TABLE_PREFIX."airports.name, ".TABLE_PREFIX."airports.country as country

    FROM ".TABLE_PREFIX."airports ORDER BY RAND() LIMIT 1";

    $result = mysql_query( $sql );

    while ($row = mysql_fetch_row($result))

    {

    echo"<h3>METAR (ICAO: ".$row[1].")</h3>";

    echo "Aeropuerto: <font color='#ff6600'>".$row[2]."</font><br />";

    $adresse = 'http://metar.vatsim.net/metar.php?id=';

    $homepage = file_get_contents($adresse.''.$row[1]);

    echo "<font color='#2997ba'>".$homepage."<font>";

    }

    ?>

    </div>

  2. You can also try this

    [b]	Ultimos Arrivos[/b]
    
    
    ';
    echo '';
    echo '';
    echo '';
    echo '';
    echo '';
    echo '';
    
    echo '';
    
    foreach ($pireps as $pirep)
    {
    
    $pilotinfo = PilotData::getPilotData($pirep->pilotid);
    $pilotid = PilotData::getPilotCode($pilotinfo->code, $pilotinfo->pilotid);
    
    echo "";
    echo '';
    echo "";
    //echo "";
    echo "";
    echo "";
    echo "";
    echo "";
    echo "";
    }
    echo "</p>										 							Vuelo							Tiempo							Piloto							Landing Rate							Aeronave													[img='.SITE_URL.]							$pirep->code $pirep->flightnum							$pirep->depicao - $pirep->arricao							$pirep->flighttime							$pilotinfo->firstname $pilotinfo->lastname							echo $pirep->landingrate							echo $pirep->aircraft			
    ";
    }
    ?>

×
×
  • Create New...