source: trunk/www/dch/shiftinfo.php@ 15370

Last change on this file since 15370 was 15312, checked in by Daniela Dorner, 12 years ago
added (page for magic shifter to get info about fact shift)
File size: 1.4 KB
Line 
1<html>
2<head>
3 <meta name="Author" content="The FACT Group" />
4 <meta http-equiv="content-type" content="text/html; charset=utf-8" />
5 <title>FACT Project</title>
6 <link rel="StyleSheet" type="text/css" href="../style.css" />
7</head>
8
9
10<body>
11
12
13<a href='https://www.fact-project.org/smartfact'>Is FACT taking data?</a><br>
14Who is on shift?
15(from <a href='https://www.fact-project.org/shift'>FACT shift plan<a>
16and <a href='https://www.fact-project.org/logbook/memberlist.php'>FACT logbook<a>)
17
18<?php
19$date=date("Ymd", mktime(0,0,date("H"-13),date("m"), date("d"), date("Y")));
20echo "<br> &nbsp;&nbsp;Night: ".$date." (date of sunset) <br>";
21$query="SELECT u FROM calendar.data WHERE CONCAT(y, LPAD(m+1, 2, 0), LPAD(d,2,0))='".$date."' AND x=0 ";
22//echo $query;
23include ("db.php");
24$db_id = mysql_connect($host, $user, $pw);
25$result = mysql_query($query);
26echo "&nbsp;&nbsp;Contact Info: <br>\n <ul>\n";
27while ($row = mysql_fetch_row($result))
28{
29 //echo "&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;".$row[0]." ";
30 $query2="SELECT usertitle, fid8 FROM logbook.userfields LEFT JOIN logbook.users ON (uid=ufid) WHERE username='".$row[0]."'";
31 //echo $query2;
32 $result2 = mysql_query($query2);
33 while ($row2 = mysql_fetch_row($result2))
34 {
35 echo "<li>".$row2[0].": ".$row2[1]."</li>\n";
36 }
37 mysql_free_result($result2);
38}
39echo "</ul>\n";
40mysql_free_result($result);
41
42?>
43
44</body>
45</html>
Note: See TracBrowser for help on using the repository browser.