Fourth pass at adding key files
This commit is contained in:
		
							
								
								
									
										205
									
								
								site/slowtwitch.com/www/tick/viewer_mobile.php
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										205
									
								
								site/slowtwitch.com/www/tick/viewer_mobile.php
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,205 @@
 | 
			
		||||
<?require ("global.php");?>
 | 
			
		||||
<?php
 | 
			
		||||
 | 
			
		||||
$link = "dynamic";
 | 
			
		||||
if (isset($_GET['link'])) { $link = $_GET['link']; }
 | 
			
		||||
 | 
			
		||||
$stageID = 0;
 | 
			
		||||
if (isset($_GET['ID']))
 | 
			
		||||
{
 | 
			
		||||
  $stageID = $_GET['ID'];
 | 
			
		||||
  
 | 
			
		||||
  $query = "SELECT events.name as event_name, stages.*, DATE_FORMAT(stages.date, '%b %e, %Y') AS datef FROM events, stages WHERE events.ID = stages.eventID AND stages.ID = $stageID";
 | 
			
		||||
  $result = mysql_query($query, $db);
 | 
			
		||||
  
 | 
			
		||||
  if ($result)
 | 
			
		||||
    {
 | 
			
		||||
      while ($r = mysql_fetch_array($result))
 | 
			
		||||
	{
 | 
			
		||||
	  $event_name = $r['event_name'];
 | 
			
		||||
	  $eventID = $r['eventID'];
 | 
			
		||||
	  $name = $r['name'];
 | 
			
		||||
	  $date = $r['datef'];
 | 
			
		||||
	  $start_location = $r['start_location'];
 | 
			
		||||
	  $end_location = $r['end_location'];
 | 
			
		||||
	  $distance = $r['distance'];
 | 
			
		||||
	  $refresh = $r['refresh'];
 | 
			
		||||
	  $tick_sequence = $r['tick_sequence'];
 | 
			
		||||
	  $refresh_type = $r['refresh_type'];
 | 
			
		||||
	  $mobile_notes = $r['mobile_notes'];
 | 
			
		||||
	  $notes = $r['notes'];
 | 
			
		||||
	}
 | 
			
		||||
      mysql_free_result($result);
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
?>
 | 
			
		||||
 | 
			
		||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
 | 
			
		||||
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
 | 
			
		||||
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:v="urn:schemas-microsoft-com:vml">
 | 
			
		||||
<head>
 | 
			
		||||
<META HTTP-EQUIV="charset" CONTENT="UTF-8">
 | 
			
		||||
<title>VeloNews :: Live Race Coverage</title>
 | 
			
		||||
<style type="text/css">
 | 
			
		||||
<!--
 | 
			
		||||
 | 
			
		||||
.text
 | 
			
		||||
{
 | 
			
		||||
font-family : Verdana, Arial, Geneva, Helvetica;
 | 
			
		||||
font-size : 11px;
 | 
			
		||||
color : #000000;
 | 
			
		||||
line-height : 120%;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
.smtext
 | 
			
		||||
{
 | 
			
		||||
font-family : Verdana, Arial, Geneva, Helvetica;
 | 
			
		||||
font-size : 10px;
 | 
			
		||||
color : #000000;
 | 
			
		||||
line-height : 120%;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
.bigtext
 | 
			
		||||
{
 | 
			
		||||
font-family : Verdana, Arial, Geneva, Helvetica;
 | 
			
		||||
font-size : 14px;
 | 
			
		||||
color : #000000;
 | 
			
		||||
line-height : 120%;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
A
 | 
			
		||||
{
 | 
			
		||||
font-family : Verdana, Arial, Geneva, Helvetica;
 | 
			
		||||
font-weight : bold;
 | 
			
		||||
font-size : 11px;
 | 
			
		||||
color : #ed1c24;
 | 
			
		||||
text-decoration : none;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
A:hover
 | 
			
		||||
{
 | 
			
		||||
color : #ed1c24;
 | 
			
		||||
font-family : Verdana, Arial, Geneva, Helvetica;
 | 
			
		||||
text-decoration : underline;
 | 
			
		||||
font-weight : bold;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
-->
 | 
			
		||||
</style>
 | 
			
		||||
</head>
 | 
			
		||||
 | 
			
		||||
<body bgcolor=#ffffff marginheight=4 marginwidth=15 leftmargin=2 topmargin=4>
 | 
			
		||||
 | 
			
		||||
<form name="which">
 | 
			
		||||
<table cellspacing=1 cellpadding=1 width="300" border=1 align=center>
 | 
			
		||||
 | 
			
		||||
<tr> <!-- header -->
 | 
			
		||||
<td align=center width="100%"><? echo "$header_html"; ?></td>
 | 
			
		||||
</tr>
 | 
			
		||||
 | 
			
		||||
<tr bgcolor="#cccccc" valign=top> <!-- stage information -->
 | 
			
		||||
<td><table cellpadding=0 cellspacing=0 border=0 width="100%">
 | 
			
		||||
<tr valign=top>
 | 
			
		||||
<td><div class=text>
 | 
			
		||||
 <span class=bigtext><b><? echo "$event_name $name"; ?></b></span>
 | 
			
		||||
<br> <? echo "$date"; ?> - 
 | 
			
		||||
 <? echo "$start_location"; ?> to <? echo "$end_location"; ?>
 | 
			
		||||
<br> <? echo "$distance"; ?>
 | 
			
		||||
<!--<? if ($notes != "") { echo "<br> ${notes}"; } ?>-->
 | 
			
		||||
<? if ($mobile_notes != "") { echo "<br> ${mobile_notes}"; } ?>
 | 
			
		||||
</div></td>
 | 
			
		||||
</tr>
 | 
			
		||||
</table></td>
 | 
			
		||||
</tr>
 | 
			
		||||
 | 
			
		||||
<tr bgcolor="#dddddd">
 | 
			
		||||
<td><table border=0 cellpadding=0 cellspacing=0 width="100%">
 | 
			
		||||
<tr>
 | 
			
		||||
<td align=center><div class=text>
 | 
			
		||||
<b>Other stages: </b>
 | 
			
		||||
<select name=stage class=text onChange="location.href = document.which.stage.options[document.which.stage.selectedIndex].value">
 | 
			
		||||
 | 
			
		||||
<?php
 | 
			
		||||
 | 
			
		||||
$query = "SELECT * FROM stages WHERE eventID = $eventID AND (status = 'ongoing' OR status = 'complete') ORDER BY date";
 | 
			
		||||
$result = mysql_query($query, $db);
 | 
			
		||||
 | 
			
		||||
if ($result)
 | 
			
		||||
{
 | 
			
		||||
    while ($r = mysql_fetch_array($result))
 | 
			
		||||
    {
 | 
			
		||||
      $location = "/tick/viewer_mobile.php?ID=" . $r['ID'];
 | 
			
		||||
      if ($link == "static")
 | 
			
		||||
	{
 | 
			
		||||
	  $location = "stage" . $r['ID'] . "_mobile.html";
 | 
			
		||||
	}
 | 
			
		||||
      $selected = "";
 | 
			
		||||
      if ($stageID == $r['ID']) { $selected = " selected"; }
 | 
			
		||||
      echo "<option value=\"${location}\"${selected}>${event_name} ${r['name']}</option>";
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
?>
 | 
			
		||||
</select>
 | 
			
		||||
</div></td>
 | 
			
		||||
 | 
			
		||||
<?
 | 
			
		||||
 | 
			
		||||
if (($popup_link != "") && ($popup_position == "stages"))
 | 
			
		||||
{
 | 
			
		||||
  echo "<td align=center><div class=text>[";
 | 
			
		||||
  echo "<a href=\"javascript:popup('html/pop_stage" . $stageID . ".html', 300, 300);\">";
 | 
			
		||||
  echo "$popup_link" . '</a>]</div></td>';
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
?>
 | 
			
		||||
 | 
			
		||||
</tr>
 | 
			
		||||
</table></td>
 | 
			
		||||
</tr>
 | 
			
		||||
 | 
			
		||||
<tr valign=top><td><table border=0 cellpadding=0 cellspacing=0><tr valign=top>
 | 
			
		||||
<td><DIV ID="commentary" STYLE="overflow: auto; width: 300px; height: 300px;
 | 
			
		||||
            border-left: 1px gray solid; border-bottom: 1px gray solid;
 | 
			
		||||
            border-right: 1px gray solid; border-top: 1px gray solid;
 | 
			
		||||
            padding:0px; margin: 0px">
 | 
			
		||||
<dl>
 | 
			
		||||
 | 
			
		||||
<?php
 | 
			
		||||
 | 
			
		||||
$query = "SELECT *, DATE_FORMAT(ticks.timestamp, '%l:%i %p') AS timef FROM ticks WHERE ticks.stageID = $stageID ORDER BY timestamp" . $tick_sequence;
 | 
			
		||||
$result = mysql_query($query, $db);
 | 
			
		||||
 | 
			
		||||
if ($result)
 | 
			
		||||
{
 | 
			
		||||
  while ($r = mysql_fetch_array($result))
 | 
			
		||||
    {
 | 
			
		||||
      $timestamp = $r['timef'];
 | 
			
		||||
      $headline = $r['headline'];
 | 
			
		||||
      $body = $r['body'];
 | 
			
		||||
      
 | 
			
		||||
      echo "<dt class=text><b> ${timestamp}  ${headline}</b></dt>";
 | 
			
		||||
      echo "<dd class=text>${body}<p></dd>";
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
mysql_free_result($result);
 | 
			
		||||
 | 
			
		||||
?>
 | 
			
		||||
</dl></div></td>
 | 
			
		||||
 | 
			
		||||
</tr></table>
 | 
			
		||||
</td>
 | 
			
		||||
</tr>
 | 
			
		||||
 | 
			
		||||
</tr></table></td>
 | 
			
		||||
</tr>
 | 
			
		||||
 | 
			
		||||
</tr></table></td>
 | 
			
		||||
</tr>
 | 
			
		||||
 | 
			
		||||
</table>
 | 
			
		||||
</form>
 | 
			
		||||
 | 
			
		||||
</body>
 | 
			
		||||
</html>
 | 
			
		||||
		Reference in New Issue
	
	Block a user