<?php

/*

GENERIC PAGE TEMPLATE

*/


// All important root and globals.  Do not edit the next 3 lines
$DOCROOT = $_SERVER['DOCUMENT_ROOT'];
include($DOCROOT.'/includes/globals.inc');
global $GLOB;


/*************************
 Configure this part
*************************/

// This is the date of this page's last update.  Change it when you update.

$lastupdate = '2/21/2008';


// The title of the page that will display at the top of the browser

$pagetitle = 'Interviews';


// The image for the top banner

$topbanner = '/images/web-rustbanner01.jpg';


// The alternate text for the top banner

$topbanneralt = 'Interviews';


// Breadcrumbs (the trail of links that tells you where you are)

$bcstyle = 'LEVEL1';			// This should be 'HOME', 'LEVEL1' or 'LEVEL2'


// If you set $bcstyle to LEVEL1 or LEVEL2, you need this part

$bclocation  = 'Interviews';		// The is the text that will print for your current location. 


// If you set $bcstyle to LEVEL2, you also need these two

$bcparentname = 'Some Name';		// The name of the parent page to display
$bcparentlink = '/somepage.php';	// The link to the parent page (so they can click it to get back)

/*************************
STOP CONFIGURING
The rest of the page is your content.  Enjoy. 
*************************/
?>

<?php
	// Start the HTML with whatever you want the page to be called.
	html_start($pagetitle);
	// html_start(<title>) will print the starting HTML along with whatever you want in the title
?>

<?php
	// Print a banner across the top
	html_banner($topbanner, $topbanneralt);
	// html_banner(<image>, <text>) will print a banner with an image and alternate text
?>


<table width="700" align="center" cellpadding="0" cellspacing="0" border="0">
<tr>
	<td colspan="3" class="breadcrumb">
<?php
	/*******************
	This breadcrumb section will print the right trail depending on your configuration at the top of the template.
	If you know what you want, you don't need the whole thin of course, but it is easier if you leave it.
	******************/

	if($bcstyle == 'HOME')
	{
		html_breadcrumbs($bcstyle);
	}
	elseif($bcstyle == 'LEVEL1')
	{
		html_breadcrumbs($bclocation);
	}
	elseif($bcstyle == 'LEVEL2')
	{
		$bcpage = array('name' => $bcparentname, 'link' => $bcparentlink);
		html_breadcrumbs($bclocation, $bcpage);
	}
	else
	{
		html_breadcrumbs('NONE');
	}

	/*******************
	END BREADCRUMB TRAIL
	******************/
?>

	</td>
</tr>
<tr>
	<td colspan="3">
		&nbsp;
	</td>
</tr>
<tr>
	<td valign="top" width="160" class="leftnavcolumn">

<?php
	// Print the navigation bar
	include($DOCROOT.'/includes/navbar.inc');
?>
	</td>
	<td class="bodytitle" width="15">
		&nbsp;
	</td>
	<td valign="top" id="bodycell">
	<!-- START BODY CONTENT SECTION -->
		<table width="100%" align="center" cellpadding="3" cellspacing="0" border="0">
		<tr>
			<td colspan="2" class="bodytitle">
				<span class="heading">Interviews</span>
			</td>
		</tr>
<?php
if(!isset($_REQUEST['review']))
{
	echo'
		<tr> 
			<td colspan="2"> 
				<p class="maintext">We at DarkTwinCities.com are always interested in what makes the artists we
appreciate "tick." As such, we hope to bring the community many interesting
dialogues with the creative forces that inspire us. Should you have the good
fortune to be granted an interview with a person or persons you think would
be of interest to us, or just want to make a suggestion regarding someone
we should actively be pursuing for an interview, feel free to contact us <a href="http://www.darktwincities.com/email.php">here.</a></p>
			</td>

		</tr>';
}
?>

		<tr>
			<td colspan="2">
				&nbsp;
			</td>
		</tr>
		<tr>
			<td colspan="2" height="25" class="bodysubtitle1 maintext">
				DISCLAIMER: Opinions expressed in these interviews are those of the interview participants and do not reflect the opinions of DarkTwinCities.com.
			</td>
		</tr> 
		<tr>
			<td colspan="2">
				&nbsp;
			</td>
		</tr>
<?php /*******************************************/
if(isset($_REQUEST['interview']))
{
	if(!preg_match('/^[0-9]+$/', $_REQUEST['interview'])){ echo 'no such interview';}
	else{
	if($db = db_connect())
	{
		$SQL = 'SELECT id, datetime, interviewer, interviewee, interview FROM interviews WHERE id='.$_REQUEST['interview'];
		if(!$result = mysql_query($SQL, $db))
		{
			die('Query failed '.mysql_error());
		}
		else
		{
			while($set = mysql_fetch_assoc($result))
			{
				list($date, $time) = split(' ', $set['datetime']);
				echo '
				<tr>
					<td class="bodysubtitle1">
						'.$set['interviewee'].' - '.$date.' <a href="interviews.php">[return to interviews]</a>
					</td>
				</tr>
				<tr>
					<td class="bodysubtitle1 maintext" align="justify">
						Interview by <a href="copyright.php#'.$set['interviewer'].'">'.$set['interviewer'].'</a>
					</td>
				</tr>
				<tr>
					<td class="maintext">
						&nbsp;
					</td>
				</tr>
				<tr>
					<td class="maintext">
						'.$set['interview'].'
					</td>
				</tr>
				<tr>
					<td class="maintext">
						&nbsp;
					</td>
				</tr>';
			}
		}
	}
	else
	{
		die('unable to connect to db');
	}
	db_close($db);
	}
}
else
{
	include($DOCROOT.'/includes/interviews_summaries.inc');
}
/*******************************************/ ?>
		<tr>
			<td colspan="2">
				&nbsp;
			</td>
		</tr>
		</table>
	<!-- STOP BODY CONTENT SECTION -->
	</td> 
</tr> 
<tr>
	<td colspan="3" class="bodytitle">
		&nbsp;
	</td>
</tr>
<tr>
	<td colspan="3" class="footer">
		<table width="100%" border="0" cellspacing="0" cellpadding="0">
		<tr>
			<td>
				<?php html_footer(); ?>
			</td>
			<td width="150" class="lastupdate">
				Last update: <?php echo $lastupdate; ?>
			</td>
		</tr>
		</table>
	</td>
        <!-- end of main body subtable -->
</tr>
</table>

<?
include($DOCROOT.'/includes/foot.inc');
?>

</body>
</html>
