<?php header('Content-type: text/html; charset=utf-8'); ?>
<?php
  /* STEP 1: LOAD RECORDS - Copy this PHP code block near the TOP of your page */
  
  // load viewer library
  $libraryPath = 'cmsAdmin/lib/viewer_functions.php';
  $dirsToCheck = array('/websites/ge/geneticalliance.org.au/','','../','../../','../../../');
  foreach ($dirsToCheck as $dir) { if (@include_once("$dir$libraryPath")) { break; }}
  if (!function_exists('getRecords')) { die("Couldn't load viewer library, check filepath in sourcecode."); }

  // load record from 'news_intro'
  list($news_introRecords, $news_introMetaData) = getRecords(array(
    'tableName'   => 'news_intro',
    'where'       => "`num` = '1'",
    'loadUploads' => true,
    'allowSearch' => false,
    'limit'       => '1',
  ));
  $news_introRecord = @$news_introRecords[0]; // get first record
  if (!$news_introRecord) { dieWith404("Record not found!"); } // show error message if no record found
  
  // load records from 'ga_support_links'
  list($ga_support_linksRecords, $ga_support_linksMetaData) = getRecords(array(
    'tableName'   => 'ga_support_links',
    'loadUploads' => true,
    'allowSearch' => false,
  ));


  // load records from 'quick_links'
  list($quick_linksRecords, $quick_linksMetaData) = getRecords(array(
    'tableName'   => 'quick_links',
    'loadUploads' => true,
    'allowSearch' => false,
  ));


    // load record from 'contact_us'
  list($contact_usRecords, $contact_usMetaData) = getRecords(array(
    'tableName'   => 'contact_us',
    'where'       => '', // load first record
    'loadUploads' => true,
    'allowSearch' => false,
    'limit'       => '1',
  ));
  $contact_usRecord = @$contact_usRecords[0]; // get first record
  if (!$contact_usRecord) { dieWith404("Record not found!"); } // show error message if no record found

  
  // load records from 'news'
  list($newsRecords, $newsMetaData) = getRecords(array(
    'tableName'   => 'news',
    'loadUploads' => true,
    'allowSearch' => false,
  ));

  
    // load record from 'mission_statement'
  list($mission_statementRecords, $mission_statementMetaData) = getRecords(array(
    'tableName'   => 'mission_statement',
    'where'       => '', // load first record
    'loadUploads' => true,
    'allowSearch' => false,
    'limit'       => '1',
  ));
  $mission_statementRecord = @$mission_statementRecords[0]; // get first record
  if (!$mission_statementRecord) { dieWith404("Record not found!"); } // show error message if no record found


  // load records from 'page_quick_links'
  list($page_quick_linksRecords, $page_quick_linksMetaData) = getRecords(array(
    'tableName'   => 'page_quick_links',
    'loadUploads' => true,
    'allowSearch' => false,
  ));
  
    // load record from 'member_of'
  list($member_ofRecords, $member_ofMetaData) = getRecords(array(
    'tableName'   => 'member_of',
    'where'       => '', // load first record
    'loadUploads' => true,
    'allowSearch' => false,
    'limit'       => '1',
  ));
  $member_ofRecord = @$member_ofRecords[0]; // get first record
  if (!$member_ofRecord) { dieWith404("Record not found!"); } // show error message if no record found

  

?>

<!DOCTYPE html>
<html>
<head>
	<meta charset="utf-8"/>
	<meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no"/>
	<title><?php echo htmlencode($news_introRecord['title']) ?>  |  <?php echo htmlencode($news_introRecord['seo_page_title']) ?></title>
	<meta name="description" content="<?php echo htmlencode($news_introRecord['seo_meta_description']) ?>" />

	<link rel="shortcut icon" href="favicon.ico"/>

	
	<link rel="stylesheet" type="text/css" href="3dParty/bootstrap/css/bootstrap.min.css"/>
	
	<link rel="stylesheet" type="text/css" href="css/global.css"/>
	
	<link rel="stylesheet" type="text/css" href="3dParty/colorbox/colorbox.css"/>
	
	<link rel="stylesheet" type="text/css" href="css/typo.css"/>
	
	<link rel="stylesheet" type="text/css" href="css/slider.css"/>
	
	<link rel="stylesheet" type="text/css" href="css/testimonials.css"/>
	
	<link rel="stylesheet" type="text/css" href="css/portfolio.css"/>
	
	<link rel="stylesheet" type="text/css" href="css/page-nav.css"/>
	
	<link rel="stylesheet" type="text/css" href="css/comments.css"/>
	
	<link rel="stylesheet" type="text/css" href="css/social.css"/>
	
	<link rel="stylesheet" type="text/css" href="css/boxes.css"/>
		<link rel="stylesheet" type="text/css" href="css/accordion.css"/>

	

	<!--Fonts-->
	<link href='http://fonts.googleapis.com/css?family=Open+Sans:300italic,400italic,600italic,700italic,800italic,400,300,600,700,800&amp;subset=latin,cyrillic'
		  rel='stylesheet' type='text/css'/>

	<!--Fonts with Icons-->
	<link rel="stylesheet" href="3dParty/fontello/css/fontello.css"/>

</head>
<body>
<?php include_once("analyticstracking.php") ?>
<div id="pi-all">

<!-- Header -->
<?php include("genetics_header.php") ?>
<!-- End header -->

<div id="page"><!-- - - - - - - - - - SECTION - - - - - - - - - -->

<!-- Title bar -->
<div class="pi-section-w pi-section-base pi-section-base-gradient">
	<div class="pi-texture" style="background: url(img/hexagon.png) repeat;"></div>
	<div class="pi-section" style="padding: 30px 40px 26px;">
	
		<div class="pi-row">
			<div class="pi-col-sm-4 pi-center-text-xs">
				<h1 class="h2 pi-weight-300 pi-margin-bottom-5"><?php echo htmlencode($news_introRecord['title']) ?></h1>
			</div>
			<div class="pi-col-sm-8 pi-text-right pi-center-text-xs">
				<p class="lead-20 pi-weight-300 pi-margin-top-5 pi-margin-bottom-5"><?php echo htmlencode($news_introRecord['tag_line']) ?></p>
			</div>
		</div>
		
	</div>
</div>
<!-- End title bar -->

<!-- - - - - - - - - - END SECTION - - - - - - - - - -->

<!-- - - - - - - - - - SECTION - - - - - - - - - -->

<!-- Breadcrumbs -->
<div class="pi-section-w pi-border-bottom pi-section-grey">
	<div class="pi-section pi-titlebar pi-breadcrumb-only">
		<div class="pi-breadcrumb pi-center-text-xs">
			<ul>
				<li><a href="index.php">Home</a></li>
				<li><?php echo htmlencode($news_introRecord['title']) ?></li>
			</ul>
		</div>
	</div>
</div>
<!-- End breadcrumbs -->

<!-- - - - - - - - - - END SECTION - - - - - - - - - -->

<!-- - - - - - - - - - SECTION - - - - - - - - - -->

<div class="pi-section-w pi-section-white pi-slider-enabled piTooltips piSocials">
	<div class="pi-section pi-padding-bottom-10">
		
		<div class="pi-row">
		
			<div class="pi-col-sm-9 pi-padding-bottom-40">
			

				<!-- Slider -->
				<div class="pi-slider-wrapper pi-slider-arrows-inside pi-slider-show-arrow-hover pi-margin-bottom-40">
					<div class="pi-slider pi-slider-animate-opacity">

						
			<img src="http://www.geneticalliance.org.au/cmsAdmin/uploads/<?php echo htmlencode($news_introRecord['image_name']) ?>" alt="" width="100%">

						

					</div>
				</div>
				<!-- End slider -->
				

				
				
				
				<p class="lead-20"><font color="#0AB6A8">

					<?php echo htmlencode($news_introRecord['intro']) ?></p></font>
				
				
				

				
				
				
				


								

				
				
				<!-- - - - - - - - - - SECTION - - - - - - - - - -->
				



<div class="pi-section-w pi-section-white piAccordion">
	<div class="pi-section">
		
		<!-- Row -->
		<div class="pi-row">
			
							
				<!-- Accordion -->
				<div class="pi-accordion pi-behavior-toggle">
					
					<!-- Accordion item -->
					  <?php foreach ($newsRecords as $record): ?>
					  					<div class="pi-accordion-item">
						
						
						<h5 class="pi-accordion-title">
							<a href="#">
								<span class="pi-accordion-toggle"></span>
								<?php echo htmlencode($record['title']) ?>	&nbsp;&nbsp; |&nbsp;&nbsp; <font color="#72398b">&nbsp;&nbsp; <?php echo htmlencode($record['date']) ?></font>
						</a>
						</h5>

						

						
						<div class="pi-accordion-content">
							<div>
								<p>
									<?php echo htmlencode($record['details']) ?> <br>
								</p>
								


								<?php if ($record['name_or_description_on_link']): ?>
<p>
									<a target="_blank" href="<?php echo htmlencode($record['url_link']) ?>">
&#9658;&nbsp;<?php echo htmlencode($record['name_or_description_on_link']) ?></a>
								</p><?php endif; ?>
										<br>	<br>
							</div>
						</div>
					</div>
					<!-- End accordion item -->



						

						
							
							
					
					  <?php endforeach ?>

   <?php if (!$newsRecords): ?>
      No records were found!<br/><br/>
    <?php endif ?>			
					
					
				
					
				</div>
				<!-- End accordion -->
				
			
			
		</div>
		<!-- End row -->
		
	</div>
</div>

<!-- - - - - - - - - - END SECTION - - - - - - - - - -->
	

	
			
									
			




			</div>
		
			<div class="pi-sidebar pi-col-sm-3">
				

				
				<!-- Categories -->
				<div class="pi-sidebar-block pi-padding-bottom-40">
					<h3 class="h6 pi-uppercase pi-weight-700 pi-letter-spacing pi-has-bg pi-margin-bottom-15">
						Quick links
					</h3>
					 <?php foreach ($page_quick_linksRecords as $record): ?>
					<ul class="pi-list-with-icons pi-list-icons-right-open">
						<li><a href="<?php echo htmlencode($record['link_url']) ?>"><strong><font color="#5f1a71"><?php echo htmlencode($record['title']) ?></a></font></strong> </li>
					</ul>
					 <?php endforeach ?>

    				<?php if (!$page_quick_linksRecords): ?>
     				 No records were found!<br/><br/>
    				<?php endif ?>
				</div>
				<!-- End categories -->
				

<!-- Tweets -->
				<div class="pi-sidebar-block pi-padding-bottom-40">
					<h3 class="h6 pi-uppercase pi-weight-700 pi-letter-spacing pi-has-bg pi-margin-bottom-20">
						Latest Tweets
					</h3>
					            <a class="twitter-timeline"  width="300" data-chrome="noborders" href="https://twitter.com/GeneticAll_AU" data-widget-id="577652740483981312">Tweets by @GeneticAll_AU</a>
            <script>!function(d,s,id){var js,fjs=d.getElementsByTagName(s)[0],p=/^http:/.test(d.location)?'http':'https';if(!d.getElementById(id)){js=d.createElement(s);js.id=id;js.src=p+"://platform.twitter.com/widgets.js";fjs.parentNode.insertBefore(js,fjs);}}(document,"script","twitter-wjs");</script>				</div>
				<!-- End tweets -->
				
				<!-- Testimonial -->
				<div class="pi-sidebar-block pi-padding-bottom-40">
					<h3 class="h6 pi-uppercase pi-weight-700 pi-letter-spacing pi-has-bg pi-margin-bottom-20">
						Our mission statement
					</h3>
					<div class="pi-testimonial pi-testimonial-author-with-icon">
						<div class="pi-testimonial-content pi-testimonial-content-quotes">
							<p><span style="font-size: 13px"><?php echo htmlencode($mission_statementRecord['mission_statement']) ?></p></font>
						</div>
						
					</div>
				</div>
				<!-- End testimonial -->
				
			</div>
			
		</div>
		
	</div>
</div>

<!-- - - - - - - - - - END SECTION - - - - - - - - - -->

</div>

<!-- Footer -->
<?php include("genetics_footer.php") ?>