Location: PHPKode > scripts > Weight Loss Recipe Book > weight-loss-recipe-book/wlrb-recipes.php
<?php 
	include('wlrb_files/functions/functions_general.php');
	include('wlrb_files/config.php');
	//$custom_vars = getCustomVars();
	$result = mysql_query('
		SELECT *
		FROM wlrb_categories
		WHERE wlrb_categories_id = "' .  $_GET['category'] . '"');
	$category = mysql_fetch_array($result);
	$result = mysql_query('
		SELECT *
		FROM wlrb_recipes
		WHERE wlrb_categories_id = "' . $_GET['category'] . '"
			and wlrb_recipes_approved = 1');
	while ($row = mysql_fetch_array($result)) {
		if ($row['wlrb_recipes_submitter'] != '') {
			$row['wlrb_recipes_submitter'] = ' - Submitted by ' . $row['wlrb_recipes_submitter'];
		}
		$recipes .= '<a href="wlrb-recipe.php?id=' . $row['wlrb_recipes_id'] . '">' . $row['wlrb_recipes_title'] . '</a>' .$row['wlrb_recipes_submitter'] . '<br />';
	}
	if ($category['wlrb_categories_title'] == '') {
		$category['wlrb_categories_title'] = 'Miscellaneous';
	}

?>
<html>
<head>
<title>Recipe Category: <?php echo $category['wlrb_categories_title']; ?></title>
<link rel="stylesheet" type="text/css" href="wlrb_files/styles/default.css">
</head>
<body>
<div class="align-center">
	<a href="wlrb-recipe-categories.php"><img src="wlrb_files/images/browse_categories.gif" alt="Browse Categories" /></a> <a href="wlrb-submit.php"><img src="wlrb_files/images/submit_recipe.gif" alt="Submit Recipe" /></a></div>
<div class="main">
<p><a href="wlrb-recipe-categories.php">Category List</a></p>
<?php echo $result_div; ?>
<h1>Weight Loss Recipe Book - <?php echo $category['wlrb_categories_title']; ?></h1>
<?php echo $recipes; ?>
</div>
<p class="align-center">Powered by <a href="http://www.my-health-and-fitness.org">My-Health-and-Fitness.org</a></p>
</body>
</html>
Return current item: Weight Loss Recipe Book