page-87.php 1.67 KB
Newer Older
agnez's avatar
start  
agnez committed
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27
 
<?php
/**
 * page Contact
 *
 */
add_action( 'beans_post_before_markup', 'page_contact_before' );
function page_contact_before() {
?>
	<article id="snippet_creer_integrer"><div class="largeur2">	<?php
		//2 blocks
		$argscontactprod = array(
			'post_type' => 'contentpiece', 
			'orderby'=> 'title', 
			'order' => 'ASC',
			'tax_query' => array(
				array(
					'taxonomy' => 'contentpiecetype',
					'field'    => 'term_id',
					'terms'    => 16 //FIX
				)
			)
		); 
		$contactprod = new WP_Query( $argscontactprod );
		 ?><div class="uk-grid uk-grid-match"> <?php
			while ( $contactprod->have_posts() ) : $contactprod->the_post();
				?><div class="uk-width-1 uk-width-small-1-2">
agnez's avatar
agnez committed
28
					<div class="uk-panel uk-panel-box gasap-panel-box uk-panel-header">
agnez's avatar
start  
agnez committed
29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61
						<h3 class="uk-panel-title"><?php the_title(); ?></h3><?php
						if ( has_post_thumbnail() ) { the_post_thumbnail(); } 
						?><div><?php the_content(); ?></div><?php 
						edit_post_link( esc_html__( 'Edit snippet', 'beans_gasap' ), '<span class="edit-link">', '</span>' ); 				
					?></div>
				</div><?php
			 endwhile;
			 wp_reset_postdata();?>
		</div>
	</div></article>

	<article id="snippet_contact_prod">	
		<h3><?php esc_html_e( 'Produire pour les Gasaps', 'beans_gasap' ); ?></h3>
		contact form to create
	</article>

	<article id="snippet_presse">	
		<h3><?php esc_html_e( 'Presse', 'beans_gasap' ); ?></h3>
		snippet to create
	</article>

	<article id="snippet_p87">
<?php 
}

add_action( 'beans_post_after_markup', 'add_contentpieces_after_contact' );
function add_contentpieces_after_contact() {?>
	</article>
	<?php
	include (get_stylesheet_directory() . '/assets/template_parts/footer.php');
}

beans_load_document();