Minor additions: yeast info popup for bb/recipe display; narrow recipe and bb lists by style with a click on a certain style; fixed some inconsistencies in the db_connect_log.inc.php file.

This commit is contained in:
Geoff Humphrey
2010-01-05 21:44:17 +00:00
parent 279b5ea8cb
commit dec14835eb
6 changed files with 1710 additions and 1677 deletions

View File

@@ -1,4 +1,4 @@
<div id="headerContentAdmin">Yeast</div>
<div id="headerContentAdmin"><div id="help"><a href="../sections/reference.inc.php?section=yeast&source=log&KeepThis=true&TB_iframe=true&height=450&width=800" title="Yeast Reference" class="thickbox"><img src="<?php echo $imageSrc; ?>information.png" align="absmiddle" border="0" alt="Reference" /></a></div>Yeast</div>
<table>
<?php if ((($action == "edit") || ($action=="import") || ($action == "importRecipe") || ($action=="reuse")) && ($row_log['brewYeastProfile'] == "")) { ?>
<?php if ($row_log['brewYeast'] != "") { ?>

View File

@@ -60,6 +60,7 @@ $query_log = sprintf("SELECT * FROM brewing ORDER BY %s %s", $sort, $dir);
$log = mysql_query($query_log, $brewing) or die(mysql_error());
$row_log = mysql_fetch_assoc($log);
$totalRows_log = mysql_num_rows($log);
if ($style != "all") $view == "all";
}
if (($row_pref['mode'] == "2") && ($filter != "all")) {
@@ -78,7 +79,6 @@ $query_log = sprintf("SELECT * FROM brewing WHERE id = '%s'", $id);
$log = mysql_query($query_log, $brewing) or die(mysql_error());
$row_log = mysql_fetch_assoc($log);
$totalRows_log = mysql_num_rows($log);
}
@@ -91,27 +91,35 @@ elseif ($view == "all") $display = 9999999;
$pg = (isset($_REQUEST['pg']) && ctype_digit($_REQUEST['pg'])) ? $_REQUEST['pg'] : 1;
$start = $display * $pg - $display;
if ($row_pref['mode'] == "1") {
if (($row_pref['mode'] == "1") || (($row_pref['mode'] == "2") && ($filter == "all"))) {
mysql_select_db($database_brewing, $brewing);
$result = mysql_query("SELECT count(*) FROM brewing");
//$result = mysql_query("SELECT count(*) FROM brewing");
$query_result = "SELECT count(*) FROM brewing";
if ($style != "all") $query_result .= " WHERE brewStyle='$style'";
$result = mysql_query($query_result, $brewing) or die(mysql_error());
$total = mysql_result($result, 0);
$log = mysql_query("SELECT * FROM brewing ORDER BY $sort $dir LIMIT $start, $display") or die(mysql_error());
$row_log = mysql_fetch_assoc($log);
}
//$log = mysql_query("SELECT * FROM brewing ORDER BY $sort $dir LIMIT $start, $display") or die(mysql_error());
if (($row_pref['mode'] == "2") && ($filter == "all")) {
mysql_select_db($database_brewing, $brewing);
$result = mysql_query("SELECT count(*) FROM brewing");
$total = mysql_result($result, 0);
$log = mysql_query("SELECT * FROM brewing ORDER BY $sort $dir LIMIT $start, $display") or die(mysql_error());
$query_log = "SELECT * FROM brewing";
if ($style != "all") $query_log .= " WHERE brewStyle='$style'";
$query_log .= " ORDER BY $sort $dir LIMIT $start, $display";
$log = mysql_query($query_log, $brewing) or die(mysql_error());
$row_log = mysql_fetch_assoc($log);
}
if (($row_pref['mode'] == "2") && ($filter != "all")) {
mysql_select_db($database_brewing, $brewing);
$result = mysql_query("SELECT count(*) FROM brewing WHERE brewBrewerID = '".$filter."'");
//$result = mysql_query("SELECT count(*) FROM brewing WHERE brewBrewerID = '".$filter."'");
$query_result = "SELECT count(*) FROM brewing WHERE brewBrewerID='$filter'";
if ($style != "all") $query_result .= " WHERE brewStyle='$style'";
$result = mysql_query($query_result, $brewing) or die(mysql_error());
$total = mysql_result($result, 0);
$log = mysql_query("SELECT * FROM brewing WHERE brewBrewerID = '".$filter."' ORDER BY $sort $dir LIMIT $start, $display") or die(mysql_error());
//$log = mysql_query("SELECT * FROM brewing WHERE brewBrewerID = '".$filter."' ORDER BY $sort $dir LIMIT $start, $display") or die(mysql_error());
$query_log = "SELECT * FROM brewing WHERE brewBrewerID='$filter'";
if ($style != "all") $query_log .= " WHERE brewStyle='$style'";
$query_log .= " ORDER BY $sort $dir LIMIT $start, $display";
$log = mysql_query($query_log, $brewing) or die(mysql_error());
$row_log = mysql_fetch_assoc($log);
}
@@ -173,7 +181,7 @@ if ($row_pref['mode'] == "1") {
mysql_select_db($database_brewing, $brewing);
$result = mysql_query("SELECT count(*) FROM brewing");
$total = mysql_result($result, 0);
$list = mysql_query("SELECT * FROM brewing ORDER BY brewDate DESC LIMIT $start, $display");
$list = mysql_query("SELECT * FROM brewing WHERE brewArchive='' OR brewArchive='N' ORDER BY brewDate DESC LIMIT $start, $display");
$row_list = mysql_fetch_assoc($list);
}
@@ -181,7 +189,7 @@ if (($row_pref['mode'] == "2") && ($filter == "all")) {
mysql_select_db($database_brewing, $brewing);
$result = mysql_query("SELECT count(*) FROM brewing");
$total = mysql_result($result, 0);
$list = mysql_query("SELECT * FROM brewing ORDER BY brewDate DESC LIMIT $start, $display");
$list = mysql_query("SELECT * FROM brewing WHERE brewArchive='' OR brewArchive='N' ORDER BY brewDate DESC LIMIT $start, $display");
$row_list = mysql_fetch_assoc($list);
}
@@ -287,19 +295,31 @@ $pg = (isset($_REQUEST['pg']) && ctype_digit($_REQUEST['pg'])) ? $_REQUEST['pg'
$start = $display * $pg - $display;
if ($row_pref['mode'] == "1") {
mysql_select_db($database_brewing, $brewing);
$result = mysql_query("SELECT count(*) FROM recipes");
$query_result = "SELECT count(*) FROM recipes";
if ($style != "all") $query_result .= " WHERE brewStyle='$style'";
$result = mysql_query($query_result, $brewing) or die(mysql_error());
$total = mysql_result($result, 0);
$recipeList = mysql_query("SELECT * FROM recipes ORDER BY $sort $dir LIMIT $start, $display") or die(mysql_error());
//$recipeList = mysql_query("SELECT * FROM recipes ORDER BY $sort $dir LIMIT $start, $display") or die(mysql_error());
$query_recipeList = "SELECT * FROM recipes";
if ($style != "all") $query_recipeList.= " WHERE brewStyle='$style'";
$query_recipeList .= " ORDER BY $sort $dir LIMIT $start, $display";
$recipeList = mysql_query($query_recipeList, $brewing) or die(mysql_error());
$row_recipeList = mysql_fetch_assoc($recipeList);
}
if (($row_pref['mode'] == "2") && ($filter == "all")) {
mysql_select_db($database_brewing, $brewing);
$result = mysql_query("SELECT count(*) FROM recipes");
$query_result = "SELECT count(*) FROM recipes";
if ($style != "all") $query_result .= " WHERE brewStyle='$style'";
$result = mysql_query($query_result, $brewing) or die(mysql_error());
$total = mysql_result($result, 0);
$recipeList = mysql_query("SELECT * FROM recipes ORDER BY $sort $dir LIMIT $start, $display") or die(mysql_error());
$query_recipeList = "SELECT * FROM recipes";
if ($style != "all") $query_recipeList.= " WHERE brewStyle='$style'";
$query_recipeList .= " ORDER BY $sort $dir LIMIT $start, $display";
$recipeList = mysql_query($query_recipeList, $brewing) or die(mysql_error());
$row_recipeList = mysql_fetch_assoc($recipeList);
}
@@ -581,12 +601,12 @@ $totalRows_members = mysql_num_rows($members);
// Status - single user
if ($row_pref['mode'] == "1") {
mysql_select_db($database_brewing, $brewing);
$countStatus = "SELECT * FROM brewing WHERE brewStatus NOT LIKE '' ORDER BY brewStatus,brewName ASC";
$countStatus = "SELECT * FROM brewing WHERE brewStatus NOT LIKE '' AND brewArchive NOT LIKE 'Y' ORDER BY brewStatus,brewName ASC";
$query_count = mysql_query($countStatus, $brewing) or die(mysql_error());
$total_status = mysql_num_rows($query_count);
mysql_select_db($database_brewing, $brewing);
$query_status = "SELECT * FROM brewing WHERE brewStatus NOT LIKE '' ORDER BY brewStatus,brewName ASC";
$query_status = "SELECT * FROM brewing WHERE brewStatus NOT LIKE '' AND brewArchive NOT LIKE 'Y' ORDER BY brewStatus,brewName ASC";
if ($total_status > 25) $query_status .= " LIMIT 25";
$status = mysql_query($query_status, $brewing) or die(mysql_error());
$row_status = mysql_fetch_assoc($status);
@@ -597,12 +617,12 @@ $totalRows_status = mysql_num_rows($status);
// Status - multi-user
if ($row_pref['mode'] == "2") {
mysql_select_db($database_brewing, $brewing);
$countStatus = sprintf("SELECT * FROM brewing WHERE brewBrewerID = '%s' AND brewStatus NOT LIKE '%s' ORDER BY brewStatus,brewName ASC", $filter, "");
$countStatus = sprintf("SELECT * FROM brewing WHERE brewBrewerID = '%s' AND brewStatus NOT LIKE '%s' AND brewArchive NOT LIKE '%s' ORDER BY brewStatus,brewName ASC", $filter, "", "Y");
$query_count = mysql_query($countStatus, $brewing) or die(mysql_error());
$total_status = mysql_num_rows($query_count);
mysql_select_db($database_brewing, $brewing);
if ($page == "profile") $query_status = sprintf("SELECT * FROM brewing WHERE brewBrewerID = '%s' AND brewStatus NOT LIKE '%s' ORDER BY brewStatus,brewName ASC", $filter, "");
if ($page == "profile") $query_status = sprintf("SELECT * FROM brewing WHERE brewBrewerID = '%s' AND brewStatus NOT LIKE '%s' AND brewArchive NOT LIKE '%s' ORDER BY brewStatus,brewName ASC", $filter, "", "Y");
else $query_status = sprintf("SELECT * FROM brewing WHERE brewBrewerID = '%s' AND brewStatus NOT LIKE '%s' ORDER BY brewStatus,brewName,brewDate DESC", $row_log['brewBrewerID'], "");
if ($total_status > 25) $query_status .= " LIMIT 25";
$status = mysql_query($query_status, $brewing) or die(mysql_error());

View File

@@ -1,77 +1,82 @@
<?php
$dbTable = "default";
if (isset($_GET['dbTable'])) {
$dbTable = (get_magic_quotes_gpc()) ? $_GET['dbTable'] : addslashes($_GET['dbTable']);
}
$action = "default";
if (isset($_GET['action'])) {
$action = (get_magic_quotes_gpc()) ? $_GET['action'] : addslashes($_GET['action']);
}
$id = "default";
if (isset($_GET['id'])) {
$id = (get_magic_quotes_gpc()) ? $_GET['id'] : addslashes($_GET['id']);
}
$filter = "all";
if (isset($_GET['filter'])) {
$filter = (get_magic_quotes_gpc()) ? $_GET['filter'] : addslashes($_GET['filter']);
}
$section = "default";
if (isset($_GET['section'])) {
$section = (get_magic_quotes_gpc()) ? $_GET['section'] : addslashes($_GET['section']);
}
$view = "limited";
if (isset($_GET['view'])) {
$view = (get_magic_quotes_gpc()) ? $_GET['view'] : addslashes($_GET['view']);
}
$source = "default";
if (isset($_GET['source'])) {
$source = (get_magic_quotes_gpc()) ? $_GET['source'] : addslashes($_GET['source']);
}
$assoc = "default";
if (isset($_GET['assoc'])) {
$assoc = (get_magic_quotes_gpc()) ? $_GET['assoc'] : addslashes($_GET['assoc']);
}
$confirm = "default";
if (isset($_GET['confirm'])) {
$confirm = (get_magic_quotes_gpc()) ? $_GET['confirm'] : addslashes($_GET['confirm']);
}
$msg = "default";
if (isset($_GET['msg'])) {
$msg = (get_magic_quotes_gpc()) ? $_GET['msg'] : addslashes($_GET['msg']);
}
$calculate = "default";
if (isset($_GET['calculate'])) {
$calculate = (get_magic_quotes_gpc()) ? $_GET['calculate'] : addslashes($_GET['calculate']);
}
$results = "false";
if (isset($_GET['results'])) {
$results = (get_magic_quotes_gpc()) ? $_GET['results'] : addslashes($_GET['results']);
}
$reset = "default";
if (isset($_GET['reset'])) {
$reset = (get_magic_quotes_gpc()) ? $_GET['reset'] : addslashes($_GET['reset']);
}
$amt = "default";
if (isset($_GET['amt'])) {
$amt = (get_magic_quotes_gpc()) ? $_GET['amt'] : addslashes($_GET['amt']);
}
$colname_log = "-1";
if (is_numeric($_GET['id'])) {
$colname_log = (get_magic_quotes_gpc()) ? $_GET['id'] : addslashes($_GET['id']);
}
<?php
$dbTable = "default";
if (isset($_GET['dbTable'])) {
$dbTable = (get_magic_quotes_gpc()) ? $_GET['dbTable'] : addslashes($_GET['dbTable']);
}
$action = "default";
if (isset($_GET['action'])) {
$action = (get_magic_quotes_gpc()) ? $_GET['action'] : addslashes($_GET['action']);
}
$id = "default";
if (isset($_GET['id'])) {
$id = (get_magic_quotes_gpc()) ? $_GET['id'] : addslashes($_GET['id']);
}
$filter = "all";
if (isset($_GET['filter'])) {
$filter = (get_magic_quotes_gpc()) ? $_GET['filter'] : addslashes($_GET['filter']);
}
$style = "all";
if (isset($_GET['style'])) {
$style = (get_magic_quotes_gpc()) ? $_GET['style'] : addslashes($_GET['style']);
}
$section = "default";
if (isset($_GET['section'])) {
$section = (get_magic_quotes_gpc()) ? $_GET['section'] : addslashes($_GET['section']);
}
$view = "limited";
if (isset($_GET['view'])) {
$view = (get_magic_quotes_gpc()) ? $_GET['view'] : addslashes($_GET['view']);
}
$source = "default";
if (isset($_GET['source'])) {
$source = (get_magic_quotes_gpc()) ? $_GET['source'] : addslashes($_GET['source']);
}
$assoc = "default";
if (isset($_GET['assoc'])) {
$assoc = (get_magic_quotes_gpc()) ? $_GET['assoc'] : addslashes($_GET['assoc']);
}
$confirm = "default";
if (isset($_GET['confirm'])) {
$confirm = (get_magic_quotes_gpc()) ? $_GET['confirm'] : addslashes($_GET['confirm']);
}
$msg = "default";
if (isset($_GET['msg'])) {
$msg = (get_magic_quotes_gpc()) ? $_GET['msg'] : addslashes($_GET['msg']);
}
$calculate = "default";
if (isset($_GET['calculate'])) {
$calculate = (get_magic_quotes_gpc()) ? $_GET['calculate'] : addslashes($_GET['calculate']);
}
$results = "false";
if (isset($_GET['results'])) {
$results = (get_magic_quotes_gpc()) ? $_GET['results'] : addslashes($_GET['results']);
}
$reset = "default";
if (isset($_GET['reset'])) {
$reset = (get_magic_quotes_gpc()) ? $_GET['reset'] : addslashes($_GET['reset']);
}
$amt = "default";
if (isset($_GET['amt'])) {
$amt = (get_magic_quotes_gpc()) ? $_GET['amt'] : addslashes($_GET['amt']);
}
$colname_log = "-1";
if (is_numeric($_GET['id'])) {
$colname_log = (get_magic_quotes_gpc()) ? $_GET['id'] : addslashes($_GET['id']);
}
?>

View File

@@ -1,106 +1,111 @@
<?php mysql_select_db($database_brewing, $brewing);
$query_styles = sprintf("SELECT * FROM styles WHERE brewStyle='%s'", $row_log['brewStyle']);
$styles = mysql_query($query_styles, $brewing) or die(mysql_error());
$row_styles = mysql_fetch_assoc($styles);
$totalRows_styles = mysql_num_rows($styles);
?>
<div id="contentWide">
<?php
if ($totalRows_log == 0) {
?>
<table class="dataTable">
<tr>
<td class="dataHeadingList">There are currently no BrewBlogs in the database <?php if ($filter != "all") echo "for this member"; ?>.<br><br></td>
</tr>
</table>
</div>
<?php } else { ?>
<?php if ($totalRows_featured > 0) { if (($row_pref['mode'] == "1") || (($row_pref['mode'] == "2") && ($filter == "all"))) include ('featured.inc.php'); } ?>
<?php if ($totalRows_featured > 0) { if (($row_pref['mode'] == "1") || (($row_pref['mode'] == "2") && ($filter == "all"))) { ?><div id="headerContentAdmin">All <?php echo $dbName; ?></div><?php } } ?>
<table class="dataTable">
<tr>
<td colspan="9"><div id="paginate"><?php echo $total." ".$row_pref['menuBrewBlogs']." Total"; if ($total > $display) echo "&nbsp;&nbsp;&nbsp;&#8226"; if ($view == "all") echo "&nbsp;&nbsp;&nbsp;&#8226;&nbsp;&nbsp;&nbsp;"; if ($total > $display) { echo "&nbsp;&nbsp;&nbsp;"; paginate($display, $pg, $total); if ($view == "limited") { ?>&nbsp;&nbsp;&nbsp;&#8226&nbsp;&nbsp;&nbsp;<a href="?page=<?php echo $page; ?>&sort=<?php echo $sort; ?>&dir=<?php echo $dir; ?>&filter=<?php echo $filter; ?>&view=all">Entire List of <?php if (($row_pref['mode'] == "2") && ($filter != "all")) echo $row_user2['realFirstName']."'s "; echo $row_pref['menuBrewBlogs']; ?></a><?php } } if ($view == "all") { ?><a href="?page=<?php echo $page; ?>&sort=<?php echo $sort; ?>&dir=<?php echo $dir; ?>&filter=<?php echo $filter; ?>&view=limited">Limited List of <?php if (($row_pref['mode'] == "2")&& ($filter != "all")) echo $row_user2['realFirstName']."'s "; echo $row_pref['menuBrewBlogs']; ?></a><?php } ?></div></td>
</tr>
</table>
<table class="dataTable">
<tr>
<?php if (isset($_SESSION["loginUsername"])) echo "<td class=\"dataList\" width=\"1%\"><img src=\"".$imageSrc."pencil.png\" border=\"0\" align=\"absmiddle\"></td>"; ?>
<?php if (!checkmobile()) { ?><td class="dataHeadingList" width="1%">XML</td><?php } ?>
<td class="dataHeadingList" width="25%"><?php echo $dbName; ?><?php if (!checkmobile()) { ?>&nbsp;<a href="?page=<?php echo $page; ?>&sort=brewName&dir=ASC&filter=<?php echo $filter; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_up.gif" border="0" alt="Sort Ascending"></a><a href="?page=<?php echo $page; ?>&sort=brewName&dir=DESC&filter=<?php echo $filter; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_down.gif" border="0" alt="Sort Descending"></a><?php } ?></td>
<td class="dataHeadingList" width="10%">Date<?php if (!checkmobile()) { ?>&nbsp;<a href="?page=<?php echo $page; ?>&sort=brewDate&dir=ASC&filter=<?php echo $filter; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_up.gif" border="0" alt="Sort Ascending"></a><a href="?page=<?php echo $page; ?>&sort=brewDate&dir=DESC&filter=<?php echo $filter; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_down.gif" border="0" alt="Sort Descending"></a><?php } ?></td>
<td class="dataHeadingList" width="25%">Style<?php if (!checkmobile()) { ?>&nbsp;<a href="?page=<?php echo $page; ?>&sort=brewStyle&dir=ASC&filter=<?php echo $filter; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_up.gif" border="0" alt="Sort Ascending"></a><a href="?page=<?php echo $page; ?>&sort=brewStyle&dir=DESC&filter=<?php echo $filter; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_down.gif" border="0" alt="Sort Descending"></a><?php } ?></td>
<td class="dataHeadingList" width="10%">Method<?php if (!checkmobile()) { ?>&nbsp;<a href="?page=<?php echo $page; ?>&sort=brewMethod&dir=ASC&filter=<?php echo $filter; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_up.gif" border="0" alt="Sort Ascending"></a><a href="?page=<?php echo $page; ?>&sort=brewMethod&dir=DESC&filter=<?php echo $filter; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_down.gif" border="0" alt="Sort Descending"></a><?php } ?></td>
<td class="dataHeadingList" width="10%"><?php if ($row_pref['measColor'] == "EBC") echo "EBC"; else echo "SRM"; ?>/<?php if ($row_pref['measColor'] == "EBC") echo "SRM"; else echo "EBC"; if (!checkmobile()) { ?>&nbsp;<a href="?page=<?php echo $page; ?>&sort=brewLovibond&dir=ASC&filter=<?php echo $filter; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_up.gif" border="0" alt="Sort Ascending"></a><a href="?page=<?php echo $page; ?>&sort=brewLovibond&dir=DESC&filter=<?php echo $filter; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_down.gif" border="0" alt="Sort Descending"></a><?php } ?></td>
<td class="dataHeadingList" width="5%">IBU<?php if (!checkmobile()) { ?>&nbsp;<a href="?page=<?php echo $page; ?>&sort=brewBitterness&dir=ASC&filter=<?php echo $filter; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_up.gif" border="0" alt="Sort Ascending"></a><a href="?page=<?php echo $page; ?>&sort=brewBitterness&dir=DESC&filter=<?php echo $filter; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_down.gif" border="0" alt="Sort Descending"></a><?php } ?></td>
<td class="dataHeadingList" width="5%">ABV<?php if (!checkmobile()) { ?>&nbsp;<a href="?page=<?php echo $page; ?>&sort=brewOG&dir=ASC&filter=<?php echo $filter; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_up.gif" border="0" alt="Sort Ascending"></a><a href="?page=<?php echo $page; ?>&sort=brewOG&dir=DESC&filter=<?php echo $filter; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_down.gif" border="0" alt="Sort Descending"></a><?php } ?></td>
<?php if (($row_pref['mode'] == "2") && ($filter == "all")) { ?><td class="dataHeadingList">Contributor<?php if (!checkmobile()) { ?>&nbsp;<a href="?page=<?php echo $page; ?>&sort=brewBrewerID&dir=ASC&filter=<?php echo $filter; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_up.gif" border="0" alt="Sort Ascending"></a><a href="?page=<?php echo $page; ?>&sort=brewBrewerID&dir=DESC&filter=<?php echo $filter; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_down.gif" border="0" alt="Sort Descending"></a><?php } ?></td><?php } ?>
<td class="dataHeadingList center" width="1%"><img src="<?php echo $imageSrc; ?>medal_gold_3.png" border="0" alt="Awards/Competition Entires" align="baseline"></td>
</tr>
<?php do { if ($row_log['brewArchive'] != "Y") { ?>
<?php
// Get brew style information for all listed styles
mysql_select_db($database_brewing, $brewing);
$query_styles = sprintf("SELECT * FROM styles WHERE brewStyle='%s'", $row_log['brewStyle']);
$styles = mysql_query($query_styles, $brewing) or die(mysql_error());
$row_styles = mysql_fetch_assoc($styles);
$totalRows_styles = mysql_num_rows($styles);
// Get real user names
mysql_select_db($database_brewing, $brewing);
$query_user2 = sprintf("SELECT * FROM users WHERE user_name = '%s'", $row_log['brewBrewerID']);
$user2 = mysql_query($query_user2, $brewing) or die(mysql_error());
$row_user2 = mysql_fetch_assoc($user2);
$totalRows_user2 = mysql_num_rows($user2);
// Awards
$awardNewID = "b".$row_log['id'];
mysql_select_db($database_brewing, $brewing);
$query_awards2 = sprintf("SELECT * FROM awards WHERE awardBrewID='%s'", $awardNewID);
$awards2 = mysql_query($query_awards2, $brewing) or die(mysql_error());
$row_awards2 = mysql_fetch_assoc($awards2);
$totalRows_awards2 = mysql_num_rows($awards2);
?>
<tr <?php echo "style=\"background-color:$color\""; ?>>
<?php if (isset($_SESSION["loginUsername"])) { if (($row_user['userLevel'] == "1") || ($row_log['brewBrewerID'] == $loginUsername)) echo "<td class=\"dataList\"><a href=\"admin/index.php?action=edit&dbTable=brewing&id=".$row_log['id']."\"><img src=\"".$imageSrc."pencil.png\" alt=\"Edit ".$row_log['brewName']."\" title=\"Edit ".$row_log['brewName']."\" border=\"0\" align=\"absmiddle\"></a></td>"; else echo "<td>&nbsp;</td>"; } ?>
<?php if (!checkmobile()) { ?><td class="dataList"><a href="#" onclick="window.open('includes/output_beer_xml.inc.php?id=<?php echo $row_log['id']; ?>&source=<?php echo $source; ?>&brewStyle=<?php echo $row_log['brewStyle']; ?>','','height=1,width=1, scrollbars=no, toolbar=no, resizable==no, menubar=no'); return false;"><img src="<?php echo $imageSrc; ?>page_white_code.png" title="Download BeerXML" align="absmiddle" border="0" /></a><?php } ?>
<td class="dataList"><a href="index.php?page=<?php echo $destination; ?>&filter=<?php echo $row_log['brewBrewerID']; ?>&id=<?php echo $row_log['id']; ?>"><?php echo $row_log['brewName']; ?></a></td>
<td class="dataList" nowrap="nowrap"><?php $date = $row_log['brewDate']; $realdate = dateconvert2($date,3); echo $realdate; ?></td>
<td class="dataList">
<div id="moreInfo"><?php if (($totalRows_styles > 0) && (!checkmobile())) { ?><a href="#"><?php } echo $row_log['brewStyle']; if (($totalRows_styles > 0) && (!checkmobile())) { ?>
<span>
<div id="wideWrapper">
<?php include ('reference/styles.inc.php'); ?>
</div>
</span>
</a>
<?php } ?>
</div>
</td>
<td class="dataList"><?php if ($row_log['brewMethod'] != "") { echo $row_log['brewMethod']; } else echo "&nbsp;" ?></td>
<?php if (!checkmobile()) { ?>
<td class="dataList">
<?php if ($row_log['brewLovibond'] != "") { ?>
<?php include ('includes/color.inc.php'); ?>
<?php include ('includes/color_display.inc.php'); ?>
<?php } else echo "&nbsp;"; ?>
</td>
<?php } ?>
<td class="dataList"><?php if ($row_log['brewBitterness'] != "") { echo round ($row_log['brewBitterness'], 1); } else echo "&nbsp;" ?></td>
<td class="dataList"><?php if (($row_log['brewOG'] != "") && ($row_log['brewFG'] != "")) { include ('includes/abv.inc.php'); echo round ($abv, 1)."%"; } else echo "&nbsp;"; ?></td>
<?php if (($row_pref['mode'] == "2") && ($filter == "all")) { ?><td class="dataList"><a href="?page=<?php echo $page; ?>&sort=<?php echo $sort; ?>&dir=<?php echo $dir; ?>&filter=<?php echo $row_user2['user_name']; ?>&view=limited"><?php echo $row_user2['realFirstName']."&nbsp;".$row_user2['realLastName']; ?></a></td><?php } ?>
<td class="dataList center"><?php if ($totalRows_awards2 > 0) echo $totalRows_awards2; else echo "&nbsp;"; ?></td>
</tr>
<?php if ($color == $color1) { $color = $color2; } else { $color = $color1; } ?>
<?php } // end if ($row_log['brewArchive'] != "Y")
} while ($row_log = mysql_fetch_assoc($log)); ?>
</table>
<?php if ($totalRows_log > 10) { ?>
<table class="dataTable">
<tr>
<td colspan="9"><div id="paginate"><?php echo $total." ".$row_pref['menuBrewBlogs']." Total"; if ($total > $display) echo "&nbsp;&nbsp;&nbsp;&#8226"; if ($view == "all") echo "&nbsp;&nbsp;&nbsp;&#8226;&nbsp;&nbsp;&nbsp;"; if ($total > $display) { echo "&nbsp;&nbsp;&nbsp;"; paginate($display, $pg, $total); if ($view == "limited") { ?>&nbsp;&nbsp;&nbsp;&#8226&nbsp;&nbsp;&nbsp;<a href="?page=<?php echo $page; ?>&sort=<?php echo $sort; ?>&dir=<?php echo $dir; ?>&filter=<?php echo $filter; ?>&view=all">Entire List of <?php if (($row_pref['mode'] == "2") && ($filter != "all")) echo $row_user2['realFirstName']."'s "; echo $row_pref['menuBrewBlogs']; ?></a><?php } } if ($view == "all") { ?><a href="?page=<?php echo $page; ?>&sort=<?php echo $sort; ?>&dir=<?php echo $dir; ?>&filter=<?php echo $filter; ?>&view=limited">Limited List of <?php if (($row_pref['mode'] == "2")&& ($filter != "all")) echo $row_user2['realFirstName']."'s "; echo $row_pref['menuBrewBlogs']; ?></a><?php } ?></div></td>
</tr>
</table>
<?php } ?>
</div>
<?php /*
mysql_select_db($database_brewing, $brewing);
$query_styles_filter = sprintf("SELECT * FROM styles ORDER BY brewStyleGroup,brewStyleNum);
$styles_filter = mysql_query($query_styles_filter, $brewing) or die(mysql_error());
$row_styles_filter = mysql_fetch_assoc($styles_filter);
$totalRows_styles_filter = mysql_num_rows($styles_filter);
*/
?>
<div id="contentWide">
<?php
if ($totalRows_log == 0) {
?>
<table class="dataTable">
<tr>
<td class="dataHeadingList">There are currently no BrewBlogs in the database <?php if ($filter != "all") echo "for this member"; ?>.<br><br></td>
</tr>
</table>
</div>
<?php } else { ?>
<?php if ($totalRows_featured > 0) { if (($row_pref['mode'] == "1") || (($row_pref['mode'] == "2") && ($filter == "all"))) include ('featured.inc.php'); } ?>
<?php if ($totalRows_featured > 0) { if (($row_pref['mode'] == "1") || (($row_pref['mode'] == "2") && ($filter == "all"))) { ?><div id="headerContentAdmin">All <?php echo $dbName; ?></div><?php } } ?>
<table class="dataTable">
<tr>
<?php if ($style != "all") { ?>
<td><div id="breadcrumb">Filter: <?php echo $row_log['brewStyle'];?> | <a href="<?php echo "http://".$_SERVER['SERVER_NAME'].$_SERVER['SCRIPT_NAME']."?page=".$page."&filter=".$filter."&style=all&sort=".$sort."&dir=".$dir."&view=".$view."&pg=".$pg; ?>">See all styles</a></div></td>
<?php } ?>
<td><div id="paginate"><?php echo $total." ".$row_pref['menuBrewBlogs']." Total"; if ($total > $display) echo "&nbsp;&nbsp;&nbsp;&#8226"; if ($view == "all") echo "&nbsp;&nbsp;&nbsp;&#8226;&nbsp;&nbsp;&nbsp;"; if ($total > $display) { echo "&nbsp;&nbsp;&nbsp;"; paginate($display, $pg, $total); if ($view == "limited") { ?>&nbsp;&nbsp;&nbsp;&#8226&nbsp;&nbsp;&nbsp;<a href="?page=<?php echo $page; ?>&sort=<?php echo $sort; ?>&dir=<?php echo $dir; ?>&filter=<?php echo $filter; ?>&style=<?php echo $style; ?>&view=all">Entire List of <?php if (($row_pref['mode'] == "2") && ($filter != "all")) echo $row_user2['realFirstName']."'s "; echo $row_pref['menuBrewBlogs']; ?></a><?php } } if (($view == "all") && ($total < $display)) { ?><a href="?page=<?php echo $page; ?>&sort=<?php echo $sort; ?>&dir=<?php echo $dir; ?>&filter=<?php echo $filter; ?>&style=<?php echo $style; ?>&view=limited">Limited List of <?php if (($row_pref['mode'] == "2")&& ($filter != "all")) echo $row_user2['realFirstName']."'s "; echo $row_pref['menuBrewBlogs']; ?></a><?php } ?></div></td>
</tr>
</table>
<table class="dataTable">
<tr>
<?php if (isset($_SESSION["loginUsername"])) echo "<td class=\"dataList\" width=\"1%\"><img src=\"".$imageSrc."pencil.png\" border=\"0\" align=\"absmiddle\"></td>"; ?>
<?php if (!checkmobile()) { ?><td class="dataHeadingList" width="1%">XML</td><?php } ?>
<td class="dataHeadingList" width="25%"><?php echo $dbName; ?><?php if (!checkmobile()) { ?>&nbsp;<a href="?page=<?php echo $page; ?>&sort=brewName&dir=ASC&filter=<?php echo $filter; ?>&style=<?php echo $style; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_up.gif" border="0" alt="Sort Ascending"></a><a href="?page=<?php echo $page; ?>&sort=brewName&dir=DESC&filter=<?php echo $filter; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_down.gif" border="0" alt="Sort Descending"></a><?php } ?></td>
<td class="dataHeadingList" width="10%">Date<?php if (!checkmobile()) { ?>&nbsp;<a href="<?php echo "http://".$_SERVER['SERVER_NAME'].$_SERVER['SCRIPT_NAME']; ?>?page=<?php echo $page; ?>&sort=brewDate&dir=ASC&filter=<?php echo $filter; ?>&style=<?php echo $style; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_up.gif" border="0" alt="Sort Ascending"></a><a href="?page=<?php echo $page; ?>&sort=brewDate&dir=DESC&filter=<?php echo $filter; ?>&style=<?php echo $style; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_down.gif" border="0" alt="Sort Descending"></a><?php } ?></td>
<td class="dataHeadingList" width="25%">Style<?php if (!checkmobile()) { ?>&nbsp;<a href="?page=<?php echo $page; ?>&sort=brewStyle&dir=ASC&filter=<?php echo $filter; ?>&style=<?php echo $style; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_up.gif" border="0" alt="Sort Ascending"></a><a href="?page=<?php echo $page; ?>&sort=brewStyle&dir=DESC&filter=<?php echo $filter; ?>&style=<?php echo $style; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_down.gif" border="0" alt="Sort Descending"></a><?php } ?></td>
<td class="dataHeadingList" width="10%">Method<?php if (!checkmobile()) { ?>&nbsp;<a href="?page=<?php echo $page; ?>&sort=brewMethod&dir=ASC&filter=<?php echo $filter; ?>&style=<?php echo $style; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_up.gif" border="0" alt="Sort Ascending"></a><a href="?page=<?php echo $page; ?>&sort=brewMethod&dir=DESC&filter=<?php echo $filter; ?>&style=<?php echo $style; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_down.gif" border="0" alt="Sort Descending"></a><?php } ?></td>
<td class="dataHeadingList" width="10%"><?php if ($row_pref['measColor'] == "EBC") echo "EBC"; else echo "SRM"; ?>/<?php if ($row_pref['measColor'] == "EBC") echo "SRM"; else echo "EBC"; if (!checkmobile()) { ?>&nbsp;<a href="?page=<?php echo $page; ?>&sort=brewLovibond&dir=ASC&filter=<?php echo $filter; ?>&style=<?php echo $style; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_up.gif" border="0" alt="Sort Ascending"></a><a href="?page=<?php echo $page; ?>&sort=brewLovibond&dir=DESC&filter=<?php echo $filter; ?>&style=<?php echo $style; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_down.gif" border="0" alt="Sort Descending"></a><?php } ?></td>
<td class="dataHeadingList" width="5%">IBU<?php if (!checkmobile()) { ?>&nbsp;<a href="?page=<?php echo $page; ?>&sort=brewBitterness&dir=ASC&filter=<?php echo $filter; ?>&style=<?php echo $style; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_up.gif" border="0" alt="Sort Ascending"></a><a href="?page=<?php echo $page; ?>&sort=brewBitterness&dir=DESC&filter=<?php echo $filter; ?>&style=<?php echo $style; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_down.gif" border="0" alt="Sort Descending"></a><?php } ?></td>
<td class="dataHeadingList" width="5%">ABV<?php if (!checkmobile()) { ?>&nbsp;<a href="?page=<?php echo $page; ?>&sort=brewOG&dir=ASC&filter=<?php echo $filter; ?>&style=<?php echo $style; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_up.gif" border="0" alt="Sort Ascending"></a><a href="?page=<?php echo $page; ?>&sort=brewOG&dir=DESC&filter=<?php echo $filter; ?>&style=<?php echo $style; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_down.gif" border="0" alt="Sort Descending"></a><?php } ?></td>
<?php if (($row_pref['mode'] == "2") && ($filter == "all")) { ?><td class="dataHeadingList">Contributor<?php if (!checkmobile()) { ?>&nbsp;<a href="?page=<?php echo $page; ?>&sort=brewBrewerID&dir=ASC&filter=<?php echo $filter; ?>&style=<?php echo $style; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_up.gif" border="0" alt="Sort Ascending"></a><a href="?page=<?php echo $page; ?>&sort=brewBrewerID&dir=DESC&filter=<?php echo $filter; ?>&style=<?php echo $style; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_down.gif" border="0" alt="Sort Descending"></a><?php } ?></td><?php } ?>
<td class="dataHeadingList center" width="1%"><img src="<?php echo $imageSrc; ?>medal_gold_3.png" border="0" alt="Awards/Competition Entires" align="baseline"></td>
</tr>
<?php do { if ($row_log['brewArchive'] != "Y") { ?>
<?php
// Get brew style information for all listed styles
mysql_select_db($database_brewing, $brewing);
$query_styles = sprintf("SELECT * FROM styles WHERE brewStyle='%s'", $row_log['brewStyle']);
$styles = mysql_query($query_styles, $brewing) or die(mysql_error());
$row_styles = mysql_fetch_assoc($styles);
$totalRows_styles = mysql_num_rows($styles);
// Get real user names
mysql_select_db($database_brewing, $brewing);
$query_user2 = sprintf("SELECT * FROM users WHERE user_name = '%s'", $row_log['brewBrewerID']);
$user2 = mysql_query($query_user2, $brewing) or die(mysql_error());
$row_user2 = mysql_fetch_assoc($user2);
$totalRows_user2 = mysql_num_rows($user2);
// Awards
$awardNewID = "b".$row_log['id'];
mysql_select_db($database_brewing, $brewing);
$query_awards2 = sprintf("SELECT * FROM awards WHERE awardBrewID='%s'", $awardNewID);
$awards2 = mysql_query($query_awards2, $brewing) or die(mysql_error());
$row_awards2 = mysql_fetch_assoc($awards2);
$totalRows_awards2 = mysql_num_rows($awards2);
?>
<tr <?php echo "style=\"background-color:$color\""; ?>>
<?php if (isset($_SESSION["loginUsername"])) { if (($row_user['userLevel'] == "1") || ($row_log['brewBrewerID'] == $loginUsername)) echo "<td class=\"dataList\"><a href=\"admin/index.php?action=edit&dbTable=brewing&id=".$row_log['id']."\"><img src=\"".$imageSrc."pencil.png\" alt=\"Edit ".$row_log['brewName']."\" title=\"Edit ".$row_log['brewName']."\" border=\"0\" align=\"absmiddle\"></a></td>"; else echo "<td>&nbsp;</td>"; } ?>
<?php if (!checkmobile()) { ?><td class="dataList"><a href="#" onclick="window.open('includes/output_beer_xml.inc.php?id=<?php echo $row_log['id']; ?>&source=<?php echo $source; ?>&brewStyle=<?php echo $row_log['brewStyle']; ?>','','height=1,width=1, scrollbars=no, toolbar=no, resizable==no, menubar=no'); return false;"><img src="<?php echo $imageSrc; ?>page_white_code.png" title="Download BeerXML" align="absmiddle" border="0" /></a><?php } ?>
<td class="dataList"><a href="index.php?page=<?php echo $destination; ?>&filter=<?php echo $row_log['brewBrewerID']; ?>&id=<?php echo $row_log['id']; ?>"><?php echo $row_log['brewName']; ?></a></td>
<td class="dataList" nowrap="nowrap"><?php $date = $row_log['brewDate']; $realdate = dateconvert2($date,3); echo $realdate; ?></td>
<td class="dataList">
<div id="moreInfo"><?php if (($totalRows_styles > 0) && (!checkmobile())) { ?><a href="<?php if ($style == "all") echo "http://".$_SERVER['SERVER_NAME'].$_SERVER['SCRIPT_NAME']."?page=".$page."&filter=".$filter."&style=".$row_log['brewStyle']."&sort=".$sort."&dir=".$dir."&view=".$view."&pg=1"; else echo "#"; ?>" title="Filter by style: <?php echo $row_log['brewStyle']; ?>"><?php } echo $row_log['brewStyle']; if (($totalRows_styles > 0) && (!checkmobile())) { ?>
<span>
<div id="wideWrapper">
<?php include ('reference/styles.inc.php'); ?>
</div>
</span>
</a>
<?php } ?>
</div>
</td>
<td class="dataList"><?php if ($row_log['brewMethod'] != "") { echo $row_log['brewMethod']; } else echo "&nbsp;" ?></td>
<?php if (!checkmobile()) { ?>
<td class="dataList">
<?php if ($row_log['brewLovibond'] != "") { ?>
<?php include ('includes/color.inc.php'); ?>
<?php include ('includes/color_display.inc.php'); ?>
<?php } else echo "&nbsp;"; ?>
</td>
<?php } ?>
<td class="dataList"><?php if ($row_log['brewBitterness'] != "") { echo round ($row_log['brewBitterness'], 1); } else echo "&nbsp;" ?></td>
<td class="dataList"><?php if (($row_log['brewOG'] != "") && ($row_log['brewFG'] != "")) { include ('includes/abv.inc.php'); echo round ($abv, 1)."%"; } else echo "&nbsp;"; ?></td>
<?php if (($row_pref['mode'] == "2") && ($filter == "all")) { ?><td class="dataList"><a href="?page=<?php echo $page; ?>&sort=<?php echo $sort; ?>&dir=<?php echo $dir; ?>&filter=<?php echo $row_user2['user_name']; ?>&view=limited"><?php echo $row_user2['realFirstName']."&nbsp;".$row_user2['realLastName']; ?></a></td><?php } ?>
<td class="dataList center"><?php if ($totalRows_awards2 > 0) echo $totalRows_awards2; else echo "&nbsp;"; ?></td>
</tr>
<?php if ($color == $color1) { $color = $color2; } else { $color = $color1; } ?>
<?php } // end if ($row_log['brewArchive'] != "Y")
} while ($row_log = mysql_fetch_assoc($log)); ?>
</table>
<?php if ($totalRows_log > 10) { ?>
<table class="dataTable">
<tr>
<td colspan="9"><div id="paginate"><?php echo $total." ".$row_pref['menuBrewBlogs']." Total"; if ($total > $display) echo "&nbsp;&nbsp;&nbsp;&#8226"; if ($view == "all") echo "&nbsp;&nbsp;&nbsp;&#8226;&nbsp;&nbsp;&nbsp;"; if ($total > $display) { echo "&nbsp;&nbsp;&nbsp;"; paginate($display, $pg, $total); if ($view == "limited") { ?>&nbsp;&nbsp;&nbsp;&#8226&nbsp;&nbsp;&nbsp;<a href="?page=<?php echo $page; ?>&sort=<?php echo $sort; ?>&dir=<?php echo $dir; ?>&filter=<?php echo $filter; ?>&style=<?php echo $style; ?>&view=all">Entire List of <?php if (($row_pref['mode'] == "2") && ($filter != "all")) echo $row_user2['realFirstName']."'s "; echo $row_pref['menuBrewBlogs']; ?></a><?php } } if ($view == "all") { ?><a href="?page=<?php echo $page; ?>&sort=<?php echo $sort; ?>&dir=<?php echo $dir; ?>&filter=<?php echo $filter; ?>&style=<?php echo $style; ?>&view=limited">Limited List of <?php if (($row_pref['mode'] == "2")&& ($filter != "all")) echo $row_user2['realFirstName']."'s "; echo $row_pref['menuBrewBlogs']; ?></a><?php } ?></div></td>
</tr>
</table>
<?php } ?>
</div>
<?php } ?>

View File

File diff suppressed because it is too large Load Diff

View File

@@ -1,106 +1,110 @@
<?php
mysql_select_db($database_brewing, $brewing);
$query_styles = sprintf("SELECT * FROM styles WHERE brewStyle='%s'", $row_recipeList['brewStyle']);
$styles = mysql_query($query_styles, $brewing) or die(mysql_error());
$row_styles = mysql_fetch_assoc($styles);
$totalRows_styles = mysql_num_rows($styles);
?>
<div id="contentWide">
<?php
if ($total == 0)
{ ?>
<table class="dataTable">
<tr>
<td class="dataHeadingList">There are currently no recipes in the database <?php if ($filter != "all") echo "for this member"; ?>.<br><br></td>
</tr>
</table>
</div>
<?php } else { ?>
<?php if ($totalRows_featured > 0) { if (($row_pref['mode'] == "1") || (($row_pref['mode'] == "2") && ($filter == "all"))) include ('featured.inc.php'); } ?>
<?php if ($totalRows_featured > 0) { if (($row_pref['mode'] == "1") || (($row_pref['mode'] == "2") && ($filter == "all"))) { ?><div id="headerContentAdmin">All <?php echo $dbName; ?></div><?php } } ?>
<table class="dataTable">
<tr>
<td colspan="9"><div id="paginate"><?php echo $total." ".$row_pref['menuRecipes']." Total"; if ($total > $display) echo "&nbsp;&nbsp;&nbsp;&#8226"; if ($view == "all") echo "&nbsp;&nbsp;&nbsp;&#8226;&nbsp;&nbsp;&nbsp;"; if ($total > $display) { echo "&nbsp;&nbsp;&nbsp;"; paginate($display, $pg, $total); if ($view == "limited") { ?>&nbsp;&nbsp;&nbsp;&#8226&nbsp;&nbsp;&nbsp;<a href="?page=<?php echo $page; ?>&sort=<?php echo $sort; ?>&dir=<?php echo $dir; ?>&filter=<?php echo $filter; ?>&view=all">Entire List of <?php if (($row_pref['mode'] == "2") && ($filter != "all")) echo $row_user2['realFirstName']."'s "; echo $row_pref['menuRecipes']; ?></a><?php } } if ($view == "all") { ?><a href="?page=<?php echo $page; ?>&sort=<?php echo $sort; ?>&dir=<?php echo $dir; ?>&filter=<?php echo $filter; ?>&view=limited">Limited List of <?php if (($row_pref['mode'] == "2")&& ($filter != "all")) echo $row_user2['realFirstName']."'s "; echo $row_pref['menuRecipes']; ?></a><?php } ?></div></td>
</tr>
</table>
<table class="dataTable">
<tr>
<?php if (isset($_SESSION["loginUsername"])) echo "<td class=\"dataList\" width=\"1%\"><img src=\"".$imageSrc."pencil.png\" border=\"0\" align=\"absmiddle\"></td>"; ?>
<?php if (!checkmobile()) { ?><td class="dataHeadingList" width="1%">XML</td><?php } ?>
<td class="dataHeadingList" width="25%"><?php echo $dbName; ?><?php if (!checkmobile()) { ?>&nbsp;<a href="?page=<?php echo $page; ?>&sort=brewName&dir=ASC&filter=<?php echo $filter; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_up.gif" border="0" alt="Sort Ascending"></a><a href="?page=<?php echo $page; ?>&sort=brewName&dir=DESC&filter=<?php echo $filter; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_down.gif" border="0" alt="Sort Descending"><?php } ?></td>
<td class="dataHeadingList" width="25%">Style<?php if (!checkmobile()) { ?>&nbsp;<a href="?page=<?php echo $page; ?>&sort=brewStyle&dir=ASC&filter=<?php echo $filter; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_up.gif" border="0" alt="Sort Ascending"></a><a href="?page=<?php echo $page; ?>&sort=brewStyle&dir=DESC&filter=<?php echo $filter; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_down.gif" border="0" alt="Sort Descending"></a><?php } ?></td>
<td class="dataHeadingList" width="10%">Method<?php if (!checkmobile()) { ?>&nbsp;<a href="?page=<?php echo $page; ?>&sort=brewMethod&dir=ASC&filter=<?php echo $filter; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_up.gif" border="0" alt="Sort Ascending"></a><a href="?page=<?php echo $page; ?>&sort=brewMethod&dir=DESC&filter=<?php echo $filter; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_down.gif" border="0" alt="Sort Descending"></a><?php } ?></td>
<td class="dataHeadingList" width="10%"><?php if ($row_pref['measColor'] == "EBC") echo "EBC"; else echo "SRM"; ?>/<?php if ($row_pref['measColor'] == "EBC") echo "SRM"; else echo "EBC"; if (!checkmobile()) { ?>&nbsp;<a href="?page=<?php echo $page; ?>&sort=brewLovibond&dir=ASC&filter=<?php echo $filter; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_up.gif" border="0" alt="Sort Ascending"></a><a href="?page=<?php echo $page; ?>&sort=brewLovibond&dir=DESC&filter=<?php echo $filter; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_down.gif" border="0" alt="Sort Descending"></a><?php } ?></td>
<td class="dataHeadingList" width="5%">IBU<?php if (!checkmobile()) { ?>&nbsp;<a href="?page=<?php echo $page; ?>&sort=brewBitterness&dir=ASC&filter=<?php echo $filter; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_up.gif" border="0" alt="Sort Ascending"></a><a href="?page=<?php echo $page; ?>&sort=brewBitterness&dir=DESC&filter=<?php echo $filter; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_down.gif" border="0" alt="Sort Descending"></a><?php } ?></td>
<td class="dataHeadingList" width="5%">ABV<?php if (!checkmobile()) { ?>&nbsp;<a href="?page=<?php echo $page; ?>&sort=brewOG&dir=ASC&filter=<?php echo $filter; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_up.gif" border="0" alt="Sort Ascending"></a><a href="?page=<?php echo $page; ?>&sort=brewOG&dir=DESC&filter=<?php echo $filter; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_down.gif" border="0" alt="Sort Descending"></a><?php } ?></td>
<?php if (($row_pref['mode'] == "2") && ($filter == "all")) { ?><td class="dataHeadingList">Contributor<?php if (!checkmobile()) { ?>&nbsp;<a href="?page=<?php echo $page; ?>&sort=brewBrewerID&dir=ASC&filter=<?php echo $filter; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_up.gif" border="0" alt="Sort Ascending"></a><a href="?page=<?php echo $page; ?>&sort=brewBrewerID&dir=DESC&filter=<?php echo $filter; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_down.gif" border="0" alt="Sort Descending"></a><?php } ?></td><?php } ?>
<td class="dataHeadingList center" width="1%"><img src="<?php echo $imageSrc; ?>medal_gold_3.png" border="0" alt="Awards/Competition Entires" align="baseline"></td>
</tr>
<?php do { if ($row_recipeList['brewArchive'] != "Y") { ?>
<?php
// Get brew style information for all listed styles
mysql_select_db($database_brewing, $brewing);
$query_styles = sprintf("SELECT * FROM styles WHERE brewStyle='%s'", $row_recipeList['brewStyle']);
$styles = mysql_query($query_styles, $brewing) or die(mysql_error());
$row_styles = mysql_fetch_assoc($styles);
$totalRows_styles = mysql_num_rows($styles);
// Get real user names
mysql_select_db($database_brewing, $brewing);
$query_user2 = sprintf("SELECT * FROM users WHERE user_name = '%s'", $row_recipeList['brewBrewerID']);
$user2 = mysql_query($query_user2, $brewing) or die(mysql_error());
$row_user2 = mysql_fetch_assoc($user2);
$totalRows_user2 = mysql_num_rows($user2);
// Awards
$awardNewID = "r".$row_recipeList['id'];
mysql_select_db($database_brewing, $brewing);
$query_awards2 = sprintf("SELECT * FROM awards WHERE awardBrewID='%s'", $awardNewID);
$awards2 = mysql_query($query_awards2, $brewing) or die(mysql_error());
$row_awards2 = mysql_fetch_assoc($awards2);
$totalRows_awards2 = mysql_num_rows($awards2);
?>
<tr <?php echo "style=\"background-color:$color\""; ?>>
<?php if (isset($_SESSION["loginUsername"])) { if (($row_user['userLevel'] == "1") || ($row_recipeList['brewBrewerID'] == $loginUsername)) echo "<td class=\"dataList\"><a href=\"admin/index.php?action=edit&dbTable=recipes&id=".$row_recipeList['id']."\"><img src=\"".$imageSrc."pencil.png\" alt=\"Edit ".$row_recipeList['brewName']."\" title=\"Edit ".$row_recipeList['brewName']."\" border=\"0\" align=\"absmiddle\"></a></td>"; else echo "<td>&nbsp;</td>"; } ?>
<?php if (!checkmobile()) { ?><td class="dataList"><a href="#" onclick="window.open('includes/output_beer_xml.inc.php?id=<?php echo $row_recipeList['id']; ?>&source=<?php echo $source; ?>&brewStyle=<?php echo $row_recipeList['brewStyle']; ?>','','height=5,width=5, scrollbars=no, toolbar=no, resizable==no, menubar=no'); return false;"><img src="<?php echo $imageSrc; ?>page_white_code.png" title="Download BeerXML" align="absmiddle" border="0" /></a></td><?php } ?>
<td class="dataList"><a href="index.php?page=<?php echo $destination; ?>&filter=<?php echo $row_recipeList['brewBrewerID']; ?>&id=<?php echo $row_recipeList['id']; ?>"><?php echo $row_recipeList['brewName']; ?></a></td>
<td class="dataList">
<div id="moreInfo"><?php if (($totalRows_styles > 0) && (!checkmobile())) { ?><a href="#"><?php } echo $row_recipeList['brewStyle']; if (($totalRows_styles > 0) && (!checkmobile())) { ?>
<span>
<div id="wideWrapper">
<?php include ('reference/styles.inc.php'); ?>
</div>
</span>
</a>
<?php } ?>
</div>
</td>
<td class="dataList"><?php if ($row_recipeList['brewMethod'] != "") { echo $row_recipeList['brewMethod']; } else echo "&nbsp;" ?></td>
<?php if (!checkmobile()) { ?>
<td class="dataList">
<?php if ($row_recipeList['brewLovibond'] != "") { ?>
<?php include ('includes/color.inc.php'); ?>
<?php include ('includes/color_display.inc.php'); ?>
<?php } else echo "&nbsp;"; ?>
</td>
<?php } ?>
<td class="dataList"><?php if ($row_recipeList['brewBitterness'] != "") { echo round ($row_recipeList['brewBitterness'], 1); } else echo "&nbsp;" ?></td>
<td class="dataList"><?php if (($row_recipeList['brewOG'] != "") && ($row_recipeList['brewFG'] != "")) { include ('includes/abv.inc.php'); echo round ($abv, 1)."%"; } else echo "&nbsp;"; ?></td>
<?php if (($row_pref['mode'] == "2") && ($filter == "all")) { ?><td class="dataList"><a href="?page=<?php echo $page; ?>&sort=<?php echo $sort; ?>&dir=<?php echo $dir; ?>&filter=<?php echo $row_user2['user_name']; ?>&view=limited"><?php echo $row_user2['realFirstName']."&nbsp;".$row_user2['realLastName']; ?></a></td><?php } ?>
<td class="dataList center"><?php if ($totalRows_awards2 > 0) echo $totalRows_awards2; else echo "&nbsp;"; ?></td>
</tr>
<?php if ($color == $color1) { $color = $color2; } else { $color = $color1; } ?>
<?php } // end if ($row_recipeList['brewArchive'] != "Y")
} while ($row_recipeList = mysql_fetch_assoc($recipeList));
?>
</table>
<?php if ($totalRows_recipeList > 10) { ?>
<table class="dataTable">
<tr>
<td><div id="paginate"><?php echo $total." ".$row_pref['menuRecipes']." Total"; if ($total > $display) echo "&nbsp;&nbsp;&nbsp;&#8226"; if ($view == "all") echo "&nbsp;&nbsp;&nbsp;&#8226;&nbsp;&nbsp;&nbsp;"; if ($total > $display) { echo "&nbsp;&nbsp;&nbsp;"; paginate($display, $pg, $total); if ($view == "limited") { ?>&nbsp;&nbsp;&nbsp;&#8226&nbsp;&nbsp;&nbsp;<a href="?page=<?php echo $page; ?>&sort=<?php echo $sort; ?>&dir=<?php echo $dir; ?>&filter=<?php echo $filter; ?>&view=all">Entire List of <?php if (($row_pref['mode'] == "2") && ($filter != "all")) echo $row_user2['realFirstName']."'s "; echo $row_pref['menuRecipes']; ?></a><?php } } if ($view == "all") { ?><a href="?page=<?php echo $page; ?>&sort=<?php echo $sort; ?>&dir=<?php echo $dir; ?>&filter=<?php echo $filter; ?>&view=limited">Limited List of <?php if (($row_pref['mode'] == "2")&& ($filter != "all")) echo $row_user2['realFirstName']."'s "; echo $row_pref['menuRecipes']; ?></a><?php } ?></div></td>
</tr>
</table>
<?php } ?>
</div>
<?php
/* mysql_select_db($database_brewing, $brewing);
$query_styles = sprintf("SELECT * FROM styles WHERE brewStyle='%s'", $row_recipeList['brewStyle']);
$styles = mysql_query($query_styles, $brewing) or die(mysql_error());
$row_styles = mysql_fetch_assoc($styles);
$totalRows_styles = mysql_num_rows($styles);
*/
?>
<div id="contentWide">
<?php
if ($total == 0)
{ ?>
<table class="dataTable">
<tr>
<td class="dataHeadingList">There are currently no recipes in the database <?php if ($filter != "all") echo "for this member"; ?>.<br><br></td>
</tr>
</table>
</div>
<?php } else { ?>
<?php if ($totalRows_featured > 0) { if (($row_pref['mode'] == "1") || (($row_pref['mode'] == "2") && ($filter == "all"))) include ('featured.inc.php'); } ?>
<?php if ($totalRows_featured > 0) { if (($row_pref['mode'] == "1") || (($row_pref['mode'] == "2") && ($filter == "all"))) { ?><div id="headerContentAdmin">All <?php echo $dbName; ?></div><?php } } ?>
<table class="dataTable">
<tr>
<?php if ($style != "all") { ?>
<td><div id="breadcrumb">Filter: <?php echo $row_recipeList['brewStyle'];?> | <a href="<?php echo "http://".$_SERVER['SERVER_NAME'].$_SERVER['SCRIPT_NAME']."?page=".$page."&filter=".$filter."&style=all&sort=".$sort."&dir=".$dir."&view=".$view."&pg=".$pg; ?>">See all styles</a></div></td>
<?php } ?>
<td><div id="paginate"><?php echo $total." ".$row_pref['menuRecipes']." Total"; if ($total > $display) echo "&nbsp;&nbsp;&nbsp;&#8226"; if ($view == "all") echo "&nbsp;&nbsp;&nbsp;&#8226;&nbsp;&nbsp;&nbsp;"; if ($total > $display) { echo "&nbsp;&nbsp;&nbsp;"; paginate($display, $pg, $total); if ($view == "limited") { ?>&nbsp;&nbsp;&nbsp;&#8226&nbsp;&nbsp;&nbsp;<a href="?page=<?php echo $page; ?>&sort=<?php echo $sort; ?>&dir=<?php echo $dir; ?>&filter=<?php echo $filter; ?>&style=<?php echo $style; ?>&view=all">Entire List of <?php if (($row_pref['mode'] == "2") && ($filter != "all")) echo $row_user2['realFirstName']."'s "; echo $row_pref['menuRecipes']; ?></a><?php } } if (($view == "all") && ($total < $display)) { ?><a href="?page=<?php echo $page; ?>&sort=<?php echo $sort; ?>&dir=<?php echo $dir; ?>&filter=<?php echo $filter; ?>&style=<?php echo $style; ?>&view=limited">Limited List of <?php if (($row_pref['mode'] == "2")&& ($filter != "all")) echo $row_user2['realFirstName']."'s "; echo $row_pref['menuRecipes']; ?></a><?php } ?></div></td>
</tr>
</table>
<table class="dataTable">
<tr>
<?php if (isset($_SESSION["loginUsername"])) echo "<td class=\"dataList\" width=\"1%\"><img src=\"".$imageSrc."pencil.png\" border=\"0\" align=\"absmiddle\"></td>"; ?>
<?php if (!checkmobile()) { ?><td class="dataHeadingList" width="1%">XML</td><?php } ?>
<td class="dataHeadingList" width="25%"><?php echo $dbName; ?><?php if (!checkmobile()) { ?>&nbsp;<a href="?page=<?php echo $page; ?>&sort=brewName&dir=ASC&filter=<?php echo $filter; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_up.gif" border="0" alt="Sort Ascending"></a><a href="?page=<?php echo $page; ?>&sort=brewName&dir=DESC&filter=<?php echo $filter; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_down.gif" border="0" alt="Sort Descending"><?php } ?></td>
<td class="dataHeadingList" width="25%">Style<?php if (!checkmobile()) { ?>&nbsp;<a href="?page=<?php echo $page; ?>&sort=brewStyle&dir=ASC&filter=<?php echo $filter; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_up.gif" border="0" alt="Sort Ascending"></a><a href="?page=<?php echo $page; ?>&sort=brewStyle&dir=DESC&filter=<?php echo $filter; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_down.gif" border="0" alt="Sort Descending"></a><?php } ?></td>
<td class="dataHeadingList" width="10%">Method<?php if (!checkmobile()) { ?>&nbsp;<a href="?page=<?php echo $page; ?>&sort=brewMethod&dir=ASC&filter=<?php echo $filter; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_up.gif" border="0" alt="Sort Ascending"></a><a href="?page=<?php echo $page; ?>&sort=brewMethod&dir=DESC&filter=<?php echo $filter; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_down.gif" border="0" alt="Sort Descending"></a><?php } ?></td>
<td class="dataHeadingList" width="10%"><?php if ($row_pref['measColor'] == "EBC") echo "EBC"; else echo "SRM"; ?>/<?php if ($row_pref['measColor'] == "EBC") echo "SRM"; else echo "EBC"; if (!checkmobile()) { ?>&nbsp;<a href="?page=<?php echo $page; ?>&sort=brewLovibond&dir=ASC&filter=<?php echo $filter; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_up.gif" border="0" alt="Sort Ascending"></a><a href="?page=<?php echo $page; ?>&sort=brewLovibond&dir=DESC&filter=<?php echo $filter; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_down.gif" border="0" alt="Sort Descending"></a><?php } ?></td>
<td class="dataHeadingList" width="5%">IBU<?php if (!checkmobile()) { ?>&nbsp;<a href="?page=<?php echo $page; ?>&sort=brewBitterness&dir=ASC&filter=<?php echo $filter; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_up.gif" border="0" alt="Sort Ascending"></a><a href="?page=<?php echo $page; ?>&sort=brewBitterness&dir=DESC&filter=<?php echo $filter; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_down.gif" border="0" alt="Sort Descending"></a><?php } ?></td>
<td class="dataHeadingList" width="5%">ABV<?php if (!checkmobile()) { ?>&nbsp;<a href="?page=<?php echo $page; ?>&sort=brewOG&dir=ASC&filter=<?php echo $filter; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_up.gif" border="0" alt="Sort Ascending"></a><a href="?page=<?php echo $page; ?>&sort=brewOG&dir=DESC&filter=<?php echo $filter; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_down.gif" border="0" alt="Sort Descending"></a><?php } ?></td>
<?php if (($row_pref['mode'] == "2") && ($filter == "all")) { ?><td class="dataHeadingList">Contributor<?php if (!checkmobile()) { ?>&nbsp;<a href="?page=<?php echo $page; ?>&sort=brewBrewerID&dir=ASC&filter=<?php echo $filter; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_up.gif" border="0" alt="Sort Ascending"></a><a href="?page=<?php echo $page; ?>&sort=brewBrewerID&dir=DESC&filter=<?php echo $filter; ?>&view=<?php echo $view; ?>"><img src="<?php echo $imageSrc; ?>sort_down.gif" border="0" alt="Sort Descending"></a><?php } ?></td><?php } ?>
<td class="dataHeadingList center" width="1%"><img src="<?php echo $imageSrc; ?>medal_gold_3.png" border="0" alt="Awards/Competition Entires" align="baseline"></td>
</tr>
<?php do { if ($row_recipeList['brewArchive'] != "Y") { ?>
<?php
// Get brew style information for all listed styles
mysql_select_db($database_brewing, $brewing);
$query_styles = sprintf("SELECT * FROM styles WHERE brewStyle='%s'", $row_recipeList['brewStyle']);
$styles = mysql_query($query_styles, $brewing) or die(mysql_error());
$row_styles = mysql_fetch_assoc($styles);
$totalRows_styles = mysql_num_rows($styles);
// Get real user names
mysql_select_db($database_brewing, $brewing);
$query_user2 = sprintf("SELECT * FROM users WHERE user_name = '%s'", $row_recipeList['brewBrewerID']);
$user2 = mysql_query($query_user2, $brewing) or die(mysql_error());
$row_user2 = mysql_fetch_assoc($user2);
$totalRows_user2 = mysql_num_rows($user2);
// Awards
$awardNewID = "r".$row_recipeList['id'];
mysql_select_db($database_brewing, $brewing);
$query_awards2 = sprintf("SELECT * FROM awards WHERE awardBrewID='%s'", $awardNewID);
$awards2 = mysql_query($query_awards2, $brewing) or die(mysql_error());
$row_awards2 = mysql_fetch_assoc($awards2);
$totalRows_awards2 = mysql_num_rows($awards2);
?>
<tr <?php echo "style=\"background-color:$color\""; ?>>
<?php if (isset($_SESSION["loginUsername"])) { if (($row_user['userLevel'] == "1") || ($row_recipeList['brewBrewerID'] == $loginUsername)) echo "<td class=\"dataList\"><a href=\"admin/index.php?action=edit&dbTable=recipes&id=".$row_recipeList['id']."\"><img src=\"".$imageSrc."pencil.png\" alt=\"Edit ".$row_recipeList['brewName']."\" title=\"Edit ".$row_recipeList['brewName']."\" border=\"0\" align=\"absmiddle\"></a></td>"; else echo "<td>&nbsp;</td>"; } ?>
<?php if (!checkmobile()) { ?><td class="dataList"><a href="#" onclick="window.open('includes/output_beer_xml.inc.php?id=<?php echo $row_recipeList['id']; ?>&source=<?php echo $source; ?>&brewStyle=<?php echo $row_recipeList['brewStyle']; ?>','','height=5,width=5, scrollbars=no, toolbar=no, resizable==no, menubar=no'); return false;"><img src="<?php echo $imageSrc; ?>page_white_code.png" title="Download BeerXML" align="absmiddle" border="0" /></a></td><?php } ?>
<td class="dataList"><a href="index.php?page=<?php echo $destination; ?>&filter=<?php echo $row_recipeList['brewBrewerID']; ?>&id=<?php echo $row_recipeList['id']; ?>"><?php echo $row_recipeList['brewName']; ?></a></td>
<td class="dataList">
<div id="moreInfo"><?php if (($totalRows_styles > 0) && (!checkmobile())) { ?><a href="<?php if ($style == "all") echo "http://".$_SERVER['SERVER_NAME'].$_SERVER['SCRIPT_NAME']."?page=".$page."&filter=".$filter."&style=".$row_recipeList['brewStyle']."&sort=".$sort."&dir=".$dir."&view=".$view."&pg=1"; else echo "#"; ?>" title="Filter by style: <?php echo $row_recipeList['brewStyle']; ?>"><?php } echo $row_recipeList['brewStyle']; if (($totalRows_styles > 0) && (!checkmobile())) { ?>
<span>
<div id="wideWrapper">
<?php include ('reference/styles.inc.php'); ?>
</div>
</span>
</a>
<?php } ?>
</div>
</td>
<td class="dataList"><?php if ($row_recipeList['brewMethod'] != "") { echo $row_recipeList['brewMethod']; } else echo "&nbsp;" ?></td>
<?php if (!checkmobile()) { ?>
<td class="dataList">
<?php if ($row_recipeList['brewLovibond'] != "") { ?>
<?php include ('includes/color.inc.php'); ?>
<?php include ('includes/color_display.inc.php'); ?>
<?php } else echo "&nbsp;"; ?>
</td>
<?php } ?>
<td class="dataList"><?php if ($row_recipeList['brewBitterness'] != "") { echo round ($row_recipeList['brewBitterness'], 1); } else echo "&nbsp;" ?></td>
<td class="dataList"><?php if (($row_recipeList['brewOG'] != "") && ($row_recipeList['brewFG'] != "")) { include ('includes/abv.inc.php'); echo round ($abv, 1)."%"; } else echo "&nbsp;"; ?></td>
<?php if (($row_pref['mode'] == "2") && ($filter == "all")) { ?><td class="dataList"><a href="?page=<?php echo $page; ?>&sort=<?php echo $sort; ?>&dir=<?php echo $dir; ?>&filter=<?php echo $row_user2['user_name']; ?>&view=limited"><?php echo $row_user2['realFirstName']."&nbsp;".$row_user2['realLastName']; ?></a></td><?php } ?>
<td class="dataList center"><?php if ($totalRows_awards2 > 0) echo $totalRows_awards2; else echo "&nbsp;"; ?></td>
</tr>
<?php if ($color == $color1) { $color = $color2; } else { $color = $color1; } ?>
<?php } // end if ($row_recipeList['brewArchive'] != "Y")
} while ($row_recipeList = mysql_fetch_assoc($recipeList));
?>
</table>
<?php if ($totalRows_recipeList > 10) { ?>
<table class="dataTable">
<tr>
<td><div id="paginate"><?php echo $total." ".$row_pref['menuRecipes']." Total"; if ($total > $display) echo "&nbsp;&nbsp;&nbsp;&#8226"; if ($view == "all") echo "&nbsp;&nbsp;&nbsp;&#8226;&nbsp;&nbsp;&nbsp;"; if ($total > $display) { echo "&nbsp;&nbsp;&nbsp;"; paginate($display, $pg, $total); if ($view == "limited") { ?>&nbsp;&nbsp;&nbsp;&#8226&nbsp;&nbsp;&nbsp;<a href="?page=<?php echo $page; ?>&sort=<?php echo $sort; ?>&dir=<?php echo $dir; ?>&filter=<?php echo $filter; ?>&view=all">Entire List of <?php if (($row_pref['mode'] == "2") && ($filter != "all")) echo $row_user2['realFirstName']."'s "; echo $row_pref['menuRecipes']; ?></a><?php } } if ($view == "all") { ?><a href="?page=<?php echo $page; ?>&sort=<?php echo $sort; ?>&dir=<?php echo $dir; ?>&filter=<?php echo $filter; ?>&view=limited">Limited List of <?php if (($row_pref['mode'] == "2")&& ($filter != "all")) echo $row_user2['realFirstName']."'s "; echo $row_pref['menuRecipes']; ?></a><?php } ?></div></td>
</tr>
</table>
<?php } ?>
</div>
<?php } ?>