HEX
Server: Microsoft-IIS/8.5
System: Windows NT YDAWBH120 6.3 build 9600 (Windows Server 2012 R2 Standard Edition) AMD64
User: tentjecom_web (0)
PHP: 7.4.14
Disabled: NONE
Upload Files
File: D:/HostingSpaces/KLeeuwen/samenbouwen.in/wwwroot/wp-content/themes/samenbouwenin/single-blogs.php
<?php get_header(); ?>

<div class="aftermenubar"></div>
<?php if ( function_exists('yoast_breadcrumb') ) {
	yoast_breadcrumb('<p id="breadcrumbs">','</p>');
} ?>

<?php while ( have_posts() ) : the_post(); 
	
	endwhile;
	rewind_posts();
	
	while ( have_posts() ) : the_post(); 
		$postId = $post->ID;
		$title = get_the_title();
		$content = get_the_content();
		$image = get_field('afbeelding');
		$author = strtoupper(get_the_author());
	endwhile; 
	
/*	if(isset($_POST['is_submit_7'])) {
		
		$name = $_POST['input_1'];
		$email = $_POST['input_2'];
		$comment = $_POST['input_3'];
		if(trim($name) && trim($email) && trim($comment) && is_email($email)) {
			$time = current_time('mysql');
			$data = array(
				'comment_post_ID' => $postId,
				'comment_author' => $name,
				'comment_author_email' => $email,
				'comment_content' => $comment,
				'comment_author_IP' => $_SERVER['REMOTE_ADDR'],
				'comment_date' => $time,					
			);	
			wp_insert_comment($data);	
			?>
			<script>
				$(document).ready(function(){
					$('html, body').animate({
				        scrollTop: $("#comments").offset().top
				    }, 1000);
				});
			</script>
			<?php 
		}
	}*/
	?>
<div class="row-fluid">
	<div class="span9">
		<img src="<?php echo $image['sizes']['large']?>" alt="<?php echo $image['alt']; ?>" />
		<br><br>
		<div class="fleft">Door: <?php echo $author;?></div>
		<div class="fright"><?php the_date('j F Y')?></div>
       	<div class="clear"></div>
       	
       	<h3 class="orgtext"><?php echo $title;?></h3>
       	<br>
       	<?php echo $content;?>
       	<br>
       	<div class="orangeline"></div>
       	<div><b>OVER <?php echo $author; ?></b><br><br><?php the_author_meta('description'); ?></div>
       	<div class="orangeline"></div>
       	<div>
       		<div class="fleft"><b>DEEL DIT ARTIKEL</b></div>
       		<div class="clear"></div>
       	</div>
       	<div class="orangeline"></div>
       	<!-- <div>
       		<b>LAAT EEN REACTIE ACHTER</b><br><br>
       		Uw e-mailadres wordt niet gepubliceerd. Verplichte velden zijn gemarkeerd <span class="orgtext">*</span>
       		<br><br>
       		<div class="contact_form_wrapper">
            	<?php //gravity_form(7, false, false, false, '', false); ?>
            </div>     
       	</div>
       	<div class="orangeline"></div>
       	<div id="comments">
       	<?php $comment_count = get_comment_count($postId); ?>
       	<h3 class="orgtext">Comments (<?php echo $comment_count['approved'];?>)</h3>
       	<?php 
		$comments = array(); /*get_comments(array(
			'post_id' => $postId,
			'status' => 'approve' 
		));*/
		echo '<ul class="comments_wrapper" id="comments_wrapper">';
		foreach($comments as $c) {  ?>
		<li class="comment even thread-even depth-1 single_comment" id="li-comment-<?php echo $c->comment_ID?>">
			<div id="comment-<?php echo $c->comment_ID?>" class="darkone_div_comment border-box">
				<img alt="" src="<?php echo get_template_directory_uri()?>/imgs/avatar.png" class="avatar avatar-200 photo" height="200" width="200">		
				<div class="darkone_comment_bubble dgreybg">
					<div class="darkonecomment_meta margin-bottom12 darkone_header_font a-inherit">
						<h5 class="comment_date_meta uppercase margin-bottom6"><?php echo date('F j, Y', strtotime($c->comment_date))?></h5>
						<h4 class="comment_author_meta uppercase orgtext"><?php echo $c->comment_author;?></h4>
					</div>		
					<div class="darkone_comment_text">
						<p><?php echo $c->comment_content;?></p>
					</div>		
					
				</div>
			</div>
		</li>
<?php 	}
		echo '</ul>';
		?>
		</div> -->
	</div>
	<div class="span3">
		<h3 class="orgtext">BLOG</h3>
		<div class="recent_blogs">
		<?php 
		$args = array(
			'post_type' => array('blogs'), 
			'post_status' => 'publish', 
			'post__not_in' => array($postId),
			'posts_per_page' => 3, 
			'orderby' => 'post_date',
    		'order' => 'DESC'
		);
		$query = new WP_Query($args);
		$i = 0;
		while ( $query->have_posts() ) : $query->the_post();
			$image = get_field('afbeelding');
			echo '<div class="fleft" style="margin-right: 10px"><img src="'.$image['sizes']['blog-thumbnail'].
				'"/></div><div class="fleft"><h3><a href="'.get_permalink().'" class="bluelink">'.get_the_title().'</a></h3></div><div class="clear"></div>';
			if($i < $query->found_posts - 1)
				echo '<div class="orangeline"></div>';
			$i++;
		endwhile;
		?>
		</div>
		<br><br>
		<h3 class="orgtext">RECENTE REACTIES</h3>
		<?php 
		$comments = get_comments(array(
			'status' => 'approve',
			'number' => 4,
		));
		foreach($comments as $i => $c) {
			echo '<div>'.$c->comment_author.' op <a href="'.get_permalink($c->comment_post_ID).'" class="bluelink">'.get_the_title($c->comment_post_ID).'</a></div>';
			if($i < count($comments) - 1)
				echo '<div class="orangeline"></div>';
		}
?>
		<br><br>
		<h3 class="orgtext">TAGS</h3>
		<div class="tagcloud"><?php wp_tag_cloud(); ?></div>		
	</div>
</div>
<script type="text/javascript">
	$('#gform_7 #input_7_1').attr('tabindex','10');
	$('#gform_7 #input_7_2').attr('tabindex','11');
	$('#gform_7 #input_7_3').attr('tabindex','12');
	$('#gform_7 #gform_submit_button_7').attr('tabindex','13');

	$('#gform_7').addClass('contact_form');
</script>		




	<?php get_footer(); ?>