mirror of
https://github.com/EGroupware/egroupware.git
synced 2025-06-21 18:31:37 +02:00
Home: More detailed cloud/rain icons
This commit is contained in:
parent
147549ad1d
commit
d0d4a2e918
@ -239,6 +239,25 @@ class home_weather_portlet extends home_portlet
|
|||||||
case 'clear' :
|
case 'clear' :
|
||||||
$icon = 'sun';
|
$icon = 'sun';
|
||||||
break;
|
break;
|
||||||
|
case 'clouds':
|
||||||
|
$icon = strtolower($weather['main']);
|
||||||
|
if($weather['description'] == 'broken clouds')
|
||||||
|
{
|
||||||
|
$icon = 'cloud-sun';
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
case 'rain':
|
||||||
|
$icon = 'cloud-rain';
|
||||||
|
if(str_contains($weather['description'], 'heavy'))
|
||||||
|
{
|
||||||
|
$icon = 'cloud-rain-heavy';
|
||||||
|
}
|
||||||
|
elseif(str_contains($weather['description'], 'light'))
|
||||||
|
{
|
||||||
|
$icon = 'cloud-drizzle';
|
||||||
|
|
||||||
|
}
|
||||||
|
break;
|
||||||
default:
|
default:
|
||||||
$icon = strtolower($weather['main']);
|
$icon = strtolower($weather['main']);
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user