Changeset 1690 -- 2010-03-05 02:30:37
- Author
FreeBSE
- Comment
- 日付修正
年が酷すぎる件なので修正(2009年ってなんだよ・・・)
コメントを修正
風向がN/Aの時、無風とする事に
ビュー向けの若干の補正
Diffs
Services_WeatherUnderground/trunk/WeatherUnderground.php
@@ -4,7 +4,7 @@
*
* @author FreeBSE <freebse@live.jp> <http://panasocli.cc/wordpress>
* @package Services_WeatherUnderground
- * @version Services_WeatherUnderground v 0.1.5 2009/03/01
+ * @version Services_WeatherUnderground v 0.1.5 2010/03/05
*
*/
@@ -47,7 +47,7 @@
}
/**
- * APIを叩く
+ * WUGのAPIを叩く
* @param $query string
* @return XML
*/
@@ -124,7 +124,7 @@
* キャッシュを削除する
*/
private function cacheRemove(){
- if(!is_dir(CACHE_BASE_DIR)) return false;
+ if(!is_dir(CACHE_BASE_DIR)) return false;
$dir = scandir(CACHE_BASE_DIR);
foreach($dir as $val){
if($val !== '.' || $val !== '..' && ((int) (time() - filemtime(CACHE_BASE_DIR . $val))) > LIFE_TIME){
@@ -236,7 +236,7 @@
$wind_dir = '南西';
break;
case 'Variable':
- $wind_dir = 'N/A';
+ $wind_dir = '無風';
break;
}
return $wind_dir;
@@ -288,7 +288,7 @@
//風向
'wind_dir' => $wind_dir,
//風速
- 'wind_speed' => $mph . 'm/s',
+ 'wind_speed' => $mph . ' m/s',
//気圧
'pressure' => $this->weather['pressure_mb'] . ' hPa',
);