forked from FredBardin/phpMyHue
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdetails.php
39 lines (34 loc) · 925 Bytes
/
details.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
<?php
//============================================================================
// Router code for content of tab details
//----------------------------------------------------------------------------
// Parameter : routage target
//----------------------------------------------------------------------------
// F. Bardin 15/02/2015
//============================================================================
// Anti-hack
define('ANTI_HACK', true);
include 'include/hueapi.php';
@$rt=$_REQUEST['rt'];
@$nohide=$_REQUEST['nh']; // if set : doesn't hide details tab
switch ($rt)
{
case "lights" :
case "scenes" :
// Load groups and lights informations
$HueAPI->loadInfo("groups");
$HueAPI->loadInfo("lights");
$HueAPI->assignLightsGroup();
case "effects" :
case "rules" :
include 'include/'.$rt.'_details.php';
break;
}
if (! isset($nohide)){
?>
<SCRIPT>
$("#detail").hide();
</SCRIPT>
<?php
}
?>