Trouble Getting Nifty COmment Bubbles to Validate
-
I’m trying out Meng Gao’s nifty comment bubble, but I’m having trouble getting them to validate. https://wuhan.authenticasian.com/goodies/?p=4
So far, I fixed one of two validation problems by moving the first
<div>
outside of the<a href>
tag. The other problem is, of course, that I have a second<div>
inside the<a href>
(which is not allowed). Here’s what I have right now:<div class="comment-bubble"><a href="<?php comments_link(); ?>">
<?php if ($comment_count_cache[$post->ID]!=0) { ?>
<div class="comment-star"><?php echo $comment_count_cache[$post->ID] ?></div>
<?php } ?>
</a></div>And the stylesheet entries:
.comment-bubble {
float: right;
background-image: url(images/comment.gif);
background-repeat: no-repeat;
background-position: center center;
height: 40px;
width: 40px;
}
.comment-star {
background-image: url(images/star.gif);
background-repeat: no-repeat;
background-position: right top;
height: 20px;
width: 20px;
color: #ffffff;
text-align: center;
margin-left: auto;
padding-top: 6px;
font: 9px Georgia;
}Ibessant suggested that I use
<span class="comment-star">
instead of<div class="comment-star">
. That validated the site, but moved the comment star off to the left. Any ideas on how I could get around this would be greatly appreciated by both myself and Meng.
- The topic ‘Trouble Getting Nifty COmment Bubbles to Validate’ is closed to new replies.