<script type="text/javascript" src="../ui/js/jquery-1.6.2.min.js"></script>
<script type="text/javascript" src="../js/slide.js"></script>

<?php

include_once('../class/class.mysql.php');
$mysqlCom = new MysqlConnect();
include_once('../picasa/class.picasa.php');
extract($_GET);
$Picasa = new Picasa;
$Picasa->CarregarWebSite($empresa,$website);
	while($row = mysqli_fetch_object($Picasa->qry)){
		$album     = $row->album_picasa;
		$usuario   = $row->usuario_picasa;
		$descricao = $row->descricao;  	
	}
?>


<script>
	$(document).ready(function(e) {
        CarregarFotosPicasa('<?php echo $album;?>','<?php echo $usuario;?>','0','pnPrincipalWebSiteOut');
		ScriptVisualizarFoto('<?php echo $album;?>','<?php echo $usuario;?>');
    });

	$('#btnVerFotoWebSite').live('click',function(){
		var album = $(this).attr('album');
		var usuario = $(this).attr('usuario');
		var pag = $(this).attr('pag');
		var cont =  $(this).attr('cont');
		 CarregarFotosPicasa(album,usuario,pag,cont);
		
		
		return false;
	})
		
		
function CarregarFotosPicasa(album, usuario, pag, cont){
	$.ajax({
				 type: "POST",
				 url: "ax.website.php",
				 data: 'ax=WebSite&album='+album+'&usuario='+usuario+'&pag='+pag, 
				 beforeSend: function(){$("#"+cont).html('<div align="center" style="padding:10%"><img src="../img/ajax-loader.gif" /></div>');},
				 success: function(R){$("#"+cont).html(R).fadeIn('slow');} ,
				 error: function(R){ $("#"+cont).html('Falha ao carregar, ou tente novamente!').fadeIn('slow');
									  $("#"+cont).html('ui-state-error ui-corner-all');
									  }
			  }) //fim ajax	
}

function ScriptVisualizarFoto(album, usuario){
	
		$.ajax({
				 type: "POST",
				 url: "ax.website.php",
				 data: 'ax=ScripVisualizarFoto&album='+album+'&usuario='+usuario, 
				 beforeSend: function(){$("#pnPrincipalWebSiteOutScript").html('<div align="center" style="padding:10%"><img src="../img/ajax-loader.gif" /></div>');},
				 success: function(R){$("#pnPrincipalWebSiteOutScript").html(R).fadeIn('slow');} ,
				 error: function(R){ $("#pnPrincipalWebSiteOutScript").html('Falha ao carregar, ou tente novamente!').fadeIn('slow');
									  $("#pnPrincipalWebSiteOutScript").html('ui-state-error ui-corner-all');
									  }
			  }) //fim ajax	
	
	
}

		
</script>



<style>
 
 
 .mold{
/*Sobras*/
-moz-box-shadow: 5px 5px 5px #666666; 
-webkit-box-shadow: 5px 5px 5px #666666;
box-shadow: 5px 5px 5px #666666;

/*Arredondamento*/
-moz-border-radius: 10px; 
-webkit-border-radius: 10px;
border-radius: 10px; /* Para Opera 10.5+*/ 
border: 1px solid #CCC;

cursor:pointer;
margin-bottom:20px;

}

.mold:hover{
	-moz-opacity: 0.8;
	opacity: 0.8 ;
	filter: progid:DXImageTransform.Microsoft.Alpha(opacity=80);
	filter: alpha(opacity=80); 	
	-ms-filter: "progid:DXImageTransform.Microsoft.Alpha(opacity=80)";
}


</style>
<div align="center" id="pnTituloWebsite"><?php echo $descricao;?></div>
<div align="center" id="pnPrincipalWebSiteOut">



</div>
<div id="pnPrincipalWebSiteOutScript"></div> 