<?php

			//session_start();
			//include('database.php');
			
			include('config.php');
		
			
			$site = $_SERVER["SERVER_NAME"];
			if( ($site == "localhost") || ($site == "127.0.0.1") ) 
			{
				$db_host    = "localhost";
				$db_user   = "root";
				$db_pass   = ""; // vide à TLS et rainbow à REALMONT
				$db_name   = "projet";
			}
			
			$connexion = mysql_connect($db_host,$db_user,$db_pass); 
			if(!$connexion)
			{
				 die('Could not connect: ' . mysql_error());
			}
 
			mysql_select_db($db_name, $connexion); 
			
?>

<!------menu accordeon ------------>
					<div class="col-md-4">
					<aside>
					
					<div class="widget">
								<h2><i class="icon-bullhorn"></i> <span>Projets</span></h2>
								<div class="panel-group" id="accordion2">
<!------>
								
<?php	
				$n = sizeof($tab_liste_projet);
				for( $i=0; $i < $n ; $i++)
				{
					echo	"		<div class='panel panel-default'>
								    <div class='panel-heading'>";
?>
									<a class='accordion-toggle' data-toggle='collapse' data-parent='#accordion2' href='<?php echo "#" .$tab_famille_projet[$i]; ?>'>
<?php
					echo 			$tab_famille_projet[$i]; 
					echo 	"		</a>
								    </div>";
?>									
								    <div id='<?php echo $tab_famille_projet[$i]; ?>' class='panel-collapse collapse'>  
<?php									
					echo	"		<div class='panel-body'>
								    <ul class='nav nav-tabs nav-stacked'>";			
									$p = sizeof($tab_liste_projet[$i]);
									for( $j=0; $j < $p ; $j++)
									{
										$projet = $tab_liste_projet[$i][$j];
										echo "<li><a href='blocs.php?projet=$projet '><i class='icon-double-angle-right'></i>$projet</a></li>";
									}						
					echo	"
									</ul>
									</div>
								    </div>
									</div>";
				}			  
?>	
<!------>									  
<!--								  
								  <div class="panel panel-default">
								    <div class="panel-heading">
								      <a class="accordion-toggle" data-toggle="collapse" data-parent="#accordion2" href="#collapseTwo">
								        CSS Tools
								      </a>
								    </div>
								    <div id="collapseTwo" class="panel-collapse collapse">
								      <div class="panel-body">
								        <ul class="nav nav-tabs nav-stacked">
											<li><a href="http://www.cssportal.com/less-to-css/"><i class="icon-double-angle-right"></i> Compile LESS to CSS</a></li>
											<li><a href="http://www.cssportal.com/css-lengths/"><i class="icon-double-angle-right"></i> CSS Lengths</a></li>
											<li><a href="http://www.cssportal.com/image-to-data/"><i class="icon-double-angle-right"></i> Convert Image to Data</a></li>
											<li><a href="http://www.cssportal.com/css-color-converter/"><i class="icon-double-angle-right"></i> CSS Color Converter</a></li>
											<li><a href="http://www.cssportal.com/css-validator/"><i class="icon-double-angle-right"></i> CSS Validator</a></li>
											<li><a href="http://www.cssportal.com/css-font-preview/"><i class="icon-double-angle-right"></i> CSS Font Preview</a></li>
											<li><a href="http://www.cssportal.com/css-sprite-generator/"><i class="icon-double-angle-right"></i> CSS Sprite Generator</a></li>
											<li><a href="http://www.cssportal.com/format-css/"><i class="icon-double-angle-right"></i> Format CSS Code</a></li>
											<li><a href="http://www.cssportal.com/css-optimize/"><i class="icon-double-angle-right"></i> Optimize CSS Code</a></li>
											<li><a href="http://www.cssportal.com/online-css-editor/"><i class="icon-double-angle-right"></i> Online CSS Editor</a></li>
											<li><a href="http://www.cssportal.com/css-style-editor/"><i class="icon-double-angle-right"></i> CSS Visual Style Editor</a></li>
										</ul>
								      </div>
								    </div>
								  </div>
-->								  
<!------>								  
<!--								  
								  <div class="panel panel-default">
								    <div class="panel-heading">
								      <a class="accordion-toggle" data-toggle="collapse" data-parent="#accordion2" href="#collapseThree">
								        CSS Examples
								      </a>
								    </div>
								    <div id="collapseThree" class="panel-collapse collapse">
								      <div class="panel-body">
								        <ul class="nav nav-tabs nav-stacked">
											<li><a href="http://www.cssportal.com/animate-css/"><i class="icon-double-angle-right"></i> CSS Animations</a></li>
											<li><a href="http://www.cssportal.com/css3-preview/"><i class="icon-double-angle-right"></i> CSS3 Preview</a></li>
											<li><a href="http://www.cssportal.com/css3-preloaders/"><i class="icon-double-angle-right"></i> CSS3 Preloaders</a></li>
											<li><a href="http://www.cssportal.com/css3-shapes/"><i class="icon-double-angle-right"></i> CSS3 Shapes</a></li>
											<li><a href="http://www.cssportal.com/graphics/"><i class="icon-double-angle-right"></i> Graphics</a></li>
											<li><a href="http://www.cssportal.com/hyperlinks/"><i class="icon-double-angle-right"></i> Hyperlinks</a></li>
											<li><a href="http://www.cssportal.com/form-elements/"><i class="icon-double-angle-right"></i> Form Elements</a></li>
											<li><a href="http://www.cssportal.com/horizontal-menus/"><i class="icon-double-angle-right"></i> Horizontal Menus</a></li>
											<li><a href="http://www.cssportal.com/vertical-menus/"><i class="icon-double-angle-right"></i> Vertical Menus</a></li>
										</ul>
								      </div>
								    </div>
								  </div>
-->								  
<!------>								  
<!--								  
								  <div class="panel panel-default">
								    <div class="panel-heading">
								      <a class="accordion-toggle" data-toggle="collapse" data-parent="#accordion2" href="#collapseFour">
								        CSS Generators
								      </a>
								    </div>
								    <div id="collapseFour" class="panel-collapse collapse">
								      <div class="panel-body">
								        <ul class="nav nav-tabs nav-stacked">
											<li><a href="http://www.cssportal.com/button-maker/"><i class="icon-double-angle-right"></i> Button Maker</a></li>
											<li><a href="http://www.cssportal.com/layout-generator/"><i class="icon-double-angle-right"></i> Layout Generator</a></li>
											<li><a href="http://www.cssportal.com/css-gradient-generator/"><i class="icon-double-angle-right"></i> CSS Gradient Generator</a></li>
											<li><a href="http://www.cssportal.com/css-menu-generator/"><i class="icon-double-angle-right"></i> CSS Menu Generator</a></li>
											<li><a href="http://www.cssportal.com/css-sprite-generator/"><i class="icon-double-angle-right"></i> CSS Sprite Generator</a></li>
											<li><a href="http://www.cssportal.com/css-tooltip-generator/"><i class="icon-double-angle-right"></i> CSS Tooltip Generator</a></li>
											<li><a href="http://www.cssportal.com/css-rounded-corners/"><i class="icon-double-angle-right"></i> Rounded Corners (CSS)</a></li>
											<li><a href="http://www.cssportal.com/css-ribbon-generator/"><i class="icon-double-angle-right"></i> CSS Ribbon Generator</a></li>
											<li><a href="http://www.cssportal.com/css3-rounded-corner/"><i class="icon-double-angle-right"></i> CSS3 Rounded Corners</a></li>
											<li><a href="http://www.cssportal.com/css3-button-generator/"><i class="icon-double-angle-right"></i> CSS3 Button Generator</a></li>
											<li><a href="http://www.cssportal.com/css3-flip-switch/"><i class="icon-double-angle-right"></i> CSS3 Flip Switch Generator</a></li>
											<li><a href="http://www.cssportal.com/css3-text-rotate-generator/"><i class="icon-double-angle-right"></i> CSS3 Text Rotate Generator</a></li>
											<li><a href="http://www.cssportal.com/css3-text-shadow-generator/"><i class="icon-double-angle-right"></i> CSS3 Text Shadow Generator</a></li>
											<li><a href="http://www.cssportal.com/css3-box-shadow-generator/"><i class="icon-double-angle-right"></i> CSS3 Box Shadow Generator</a></li>
											<li><a href="http://www.cssportal.com/css3-menu-generator/"><i class="icon-double-angle-right"></i> CSS3 Menu Generator</a></li>
											<li><a href="http://www.cssportal.com/css3-rgba-generator/"><i class="icon-double-angle-right"></i> CSS3 RGBA Generator</a></li>
											<li><a href="http://www.cssportal.com/style-input-range/"><i class="icon-double-angle-right"></i> Style Input Range</a></li>
										</ul>
								      </div>
								    </div>
								  </div>
-->								  
<!------>								  

								</div>
							</div>
					
					</aside>						
					</div>

<!------ fin menu accordeon ------------>