Hello,
My website has a portfolio template where the gallery is added via a custom field. My web portfolio needs to be password protected, most importantly the gallery.
I was able to get the custom field protected, but the problem is I am now getting two password alerts/inputs, as seen here: http://destinetodesign.com/portfolio-web-design/
If you would like to compare to an unprotected portfolio: http://destinetodesign.com/portfolio-print-design/
I think this problem is new to 3.4.1
<?php
/*
Template Name: Portfolio
*/
?>
<?php get_header('port'); ?>
<?php
if ( ! post_password_required() ) {
if ( get_post_meta($post->ID, 'web-gall', true) ) : ?>
<?php echo get_post_meta($post->ID, 'web-gall', true) ?>
<?php endif; ?>
<?php } //end protected if, end meta ?>
<article>
<?php if (have_posts()) : ?>
<?php while (have_posts()) : the_post(); ?>
<div class="colone"><p><?php the_time('F jS, Y') ?></p>
<p><strong><?php the_title(); ?></strong></p>
</div>
<div class="main">
<?php the_content('Read the rest of this entry ยป'); ?>
<?php endwhile; ?>
<?php else : ?>
<p>Sorry, but you are looking for something that isn't here.</p>
<?php endif;?>
</div>
</div>
</article>
<?php get_footer('port'); ?>