<!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" lang="en-US">

<head>
<title>Moreno Travel</title>
    <link href="style.css" rel="stylesheet" type="text/css" />
    <meta http-equiv="content-type"
        content="text/html; charset=utf-8" />


<style>
img.pkgimg {padding: 2px; border: 8px #EBDAB5 solid;}
</style>
<?php include 'analytics.php'; ?>

</head>
<?php include 'header.php'; ?>

<?php

$package_id=$_GET['package_id']; 
$location_id=$_GET['location_id'];
require_once('connectvars.php');

	

$dbh = mysql_connect(hostname, username, password)

	or die("Unable to connect to MySQL");

mysql_select_db ("moreno00_travel", $dbh);


$query = sprintf("SELECT * FROM packages WHERE package_id='$package_id'");

$result = mysql_query($query);



if (!$result) {

    $message  = 'Invalid query: ' . mysql_error() . "\n";

    $message .= 'Whole query: ' . $query;

    die($message);

}

while ($row = mysql_fetch_assoc($result)) {


echo "<b><font size=\"4px\">".$row['package_name']." - ".$row['duration']."</b></font>&nbsp;&nbsp;&nbsp; <br><a href=\"downloadbrochure.php?package_id=".$row['package_id']."\" class=\"top_link\" target=\"_blank\"><span>Download Details</span></a> &nbsp; &nbsp;<a href=\"downloadbrochure2.php?package_id=".$row['package_id']."\" class=\"top_link\" target=\"_blank\"><span>Download Brochure</span></a>";


}
?>


<?php include 'destnavigation.php'; ?>


<br><br>


<?php

$package_id=$_GET['package_id']; 
$location_id=$_GET['location_id'];
require_once('connectvars.php');

	

$dbh = mysql_connect(hostname, username, password)

	or die("Unable to connect to MySQL");

mysql_select_db (dbname, $dbh);


$query = sprintf("SELECT * FROM packages WHERE package_id='$package_id'");

$result = mysql_query($query);



if (!$result) {

    $message  = 'Invalid query: ' . mysql_error() . "\n";

    $message .= 'Whole query: ' . $query;

    die($message);

}

while ($row = mysql_fetch_assoc($result)) {


echo "<align=\"right\"><div class=\"figure3\"><img width=\"240px\" src=\"pkgimg/".$row['overviewpic']."\"><br><img width=\"240px\" src=\"pkgimg/".$row['overviewpic2']."\"><br>".$row['package_name']."<br><b>Duration:</b> ".$row['duration']."<br><b>Starting Price:</b> ".$row['startingprice']."</div></align>";

echo "<b>".$row['feature']."</b><br><br><br>".$row['overview']."<h3><font color=\"#15317E\">Package Includes:</font></h3><ul>".$row['includes']."<br><br><i><b>Not Included: </b>".$row['doesnotinclude']."</i></ul>
<br>".$row['moredetails'];
}

?>


<h3><font color="#15317E">The following cities are visited:</font></h3>
<?php 
$package_id=$_GET['package_id'];
$location_id=$_GET['location_id'];
require_once('connectvars.php');
$dbh = mysql_connect(hostname, username, password)
	or die("Unable to connect to MySQL");
mysql_select_db ("moreno00_travel", $dbh);
$query = sprintf("SELECT *
FROM cities
INNER JOIN citiespackagelink ON citiespackagelink.city_id = cities.city_id
INNER JOIN packages ON packages.package_id = citiespackagelink.package_id
WHERE packages.package_id='$package_id'");

$result = mysql_query($query);
$num = mysql_num_rows($result);

if($num == "0") {

echo "Contact a Moreno Representative for cities visited or check out the itinerary for more details.";

}

else {

while ($row = mysql_fetch_assoc($result)) {

echo "
<a href=\"citydetails.php?city_id=".$row['city_id']."&location_id=".$row['location_id']."\">".$row['city_name']."</a><br>";
}}
?>
<?php

$package_id=$_GET['package_id']; 
$location_id=$_GET['location_id'];
require_once('connectvars.php');

	

$dbh = mysql_connect(hostname, username, password)

	or die("Unable to connect to MySQL");

mysql_select_db (dbname, $dbh);


$query = sprintf("SELECT * FROM packages WHERE package_id='$package_id'");

$result = mysql_query($query);



if (!$result) {

    $message  = 'Invalid query: ' . mysql_error() . "\n";

    $message .= 'Whole query: ' . $query;

    die($message);

}

while ($row = mysql_fetch_assoc($result)) {


echo $row['morecities']."</a><br>";

}

?>


<h3><font color="#15317E">The following sightseeing attractions are visted:</font></h3>
<?php 
$package_id=$_GET['package_id'];
require_once('connectvars.php');
$dbh = mysql_connect(hostname, username, password)
	or die("Unable to connect to MySQL");
mysql_select_db ("moreno00_travel", $dbh);
$query = sprintf("SELECT *
FROM info
INNER JOIN infopackagelink ON infopackagelink.info_id = info.info_id
INNER JOIN packages ON packages.package_id = infopackagelink.package_id
WHERE packages.package_id='$package_id'");

$result = mysql_query($query);
$num = mysql_num_rows($result);

if($num == "NULL") {

echo "Contact a Moreno Representative for attractions visited or check out the itinerary for more details.";

}

else {

while ($row = mysql_fetch_assoc($result)) {


echo "
<a href=\"info.php?info_id=".$row['info_id']."&location_id=".$row['location_id']."\">".$row['info_name']."</a>";
}}
?>
<?php

$package_id=$_GET['package_id']; 

require_once('connectvars.php');

	

$dbh = mysql_connect(hostname, username, password)

	or die("Unable to connect to MySQL");

mysql_select_db (dbname, $dbh);


$query = sprintf("SELECT * FROM packages WHERE package_id='$package_id'");

$result = mysql_query($query);



if (!$result) {

    $message  = 'Invalid query: ' . mysql_error() . "\n";

    $message .= 'Whole query: ' . $query;

    die($message);

}

while ($row = mysql_fetch_assoc($result)) {


echo $row['moreinfo']."</a><br>";

}

?>

<br><br>


</div>

<?php include 'footer.php'; ?>
</div>


</body>

</html>