<?php
function far_open_graph() { ?>

	<meta property="og:url" content="<?php the_permalink();?>" />
	<meta property="fb:admins" content="1132645692" />
	<meta property="fb:admins" content="644647919" />
	
	<?php if ( is_front_page() ) : ?>
	
	<meta property="og:title" content="" />
	<meta property="og:description" content="" />
	<meta property="og:image" content="" />

	<?php endif; ?>
	
	<?php
	
	if ( is_single() ) :
	
		switch ( $post->post_type ) {
			case 'profile' :
				$cover = 'portait'; break;
			case 'publication' : 
				$cover = 'cover'; break;
			case 'video-conference' : 
			case 'video-programme' : 
				$cover = 'cover_image'; break;
			default :
				$cover = 'featured_image';
		}
		switch ( $post->post_type ) {
			case 'gallery' :
				$description = 'description'; break;
			case 'profile' :
				$description = 'biography'; break;
			case 'publication' :
				$description = 'synopsis'; break;
			default :
				$description = 'lead_description';
		}
	?>
	
	<meta property="og:title" content="<?php the_title();?>" />
	<meta property="og:image" content="<?php ?>" />
	<meta property="og:description" content="<?php ?>" />
	
	<?php endif; ?>
	
	<?php
}
// add_action('wp_head', 'far_open_graph');

function far_meta_description() {
    
	if ( is_front_page() ) {
		echo '<meta name="description" content="LOOP is a platform dedicated to the study and promotion of the moving image. Founded in 2003, since its creation it offers a specialised audience a curated selection of video-related contents from challenging perspectives. LOOP yearly hosts LOOP Barcelona, a special meeting point that unfolds into a Festival, a Fair and a programme of Talks, Professional Meetings and workshops." />';
	}
}

add_action('wp_head', 'far_meta_description');
