View Full Version : Pop-Up not working on posts only home page and archive pages.

01-11-2013, 11:26 AM

I have a "daily tip" custom post type and I use the following code to display the most recent post in my sidebar (below).
The pop up only shows up on the home page, and archive pages, not on posts.

I remove the code and everything works fine again.

Do I need to use different code for this purpose? or is there something I can change to make everything work?

thank you!

my site is: http://photoshoptrainingchannel.com

<div class="sidebar_tip_day widget">
<div class="widget-wrap">
<div class="in_page_tip_day">

$args = array( 'post_type' => 'tip_of_the_day', 'posts_per_page' => 1 );
$loop = new WP_Query( $args );
while ( $loop->have_posts() ) : $loop->the_post();
echo '<div class="tip-content">';
echo '<div class="page_tip_date">';
echo '<a href="';
echo the_permalink();
echo '"/>';
echo the_date();
echo '</a> ';
echo '</div>';

echo '<h4>Tip Of The Day</h4>';
echo '</div>';

echo '<div class="tip_facebook">';
echo '<div class="fb-like" data-href="';
echo the_permalink();
echo '" data-send="false" data-layout="button_count" data-width="95" data-show-faces="false"></div>';
echo '</div>';

echo '<div class="tip_google">';
echo '<g:plusone href="';
echo get_permalink($postid);
echo '" size="medium"></g:plusone></div>';

echo '<div class="tip_twitter"> <a href="http://twitter.com/share" class="twitter-share-button" data-url="';
echo the_permalink();
echo '" data-count="horizantal">Tweet</a><script type="text/javascript" src="http://platform.twitter.com/widgets.js"></script></div>';


<div class="tip_outro"><p>Click the social share buttons above &uarr; <br/>if you liked today's <a href="http://photoshoptrainingchannel.com/tips/" title="Click Here To See Past Tips Of The Day">Tip of The Day!</a></p></div>


Jean-Christophe Bisoux
01-11-2013, 01:33 PM

Is it posible for you to activate your "daily tip" for a moment just for me to see the issue on live ?

Say me when you activate it