Hi there !!!
I would like to have the weather report in a table showing the =
following: time, wind speed, wind direction, =
temperature,dew-point,atmospheric pressure, humidity,clouds, visibility.
I found a function print_table() in the pw_text.php file and transferred =
the code into the index.php file but still doesn't work.=20
Could you please check the code below and let me know what should be =
changed.
Thank you very much.
Carlos
$output .=3D print_table() {
$data =3D $this->weather->decode_metar();
$location =3D $data['location'];
$date =3D $this->print_pretty_time($data['time']);
$wind =3D $this->print_pretty_wind($data['wind']);
$temperature =3D =
$this->print_pretty_temperature($data['temperature']);
$pressure =3D $this->print_pretty_altimeter($data['altimeter']);
$humidity =3D =
$this->print_pretty_rel_humidity($data['rel_humidity']);
if ($this->properties['orientation'] =3D=3D 'vertical') {
} else {
echo "<table border=3D"1">";
echo "\n <tr>\n";
echo " <th>' . $this->strings['location'] . "</th>\n";
echo " <th>' . $this->strings['date'] . "</th>\n";
echo " <th>' . $this->strings['wind'] . "</th>\n";
echo " <th>' . $this->strings['temperature'] . "</th>\n";
echo " <th>' . $this->strings['pressure'] . "</th>\n";
echo " <th>' . $this->strings['humidity'] . "</th>\n";
echo " </tr>\n";
echo " <td>$location</td>
<td>$date</td>
<td>$wind</td>
<td>$temperature</td>
<td>$pressure</td>
<td>$humidity%</td>
</tr>
</table>
";
}
}
}
|