Not a member of Pastebin yet?
                        Sign Up,
                        it unlocks many cool features!                    
                - Index: hackadelic-toc.php
- ===================================================================
- --- hackadelic-toc.php (revision 108955)
- +++ hackadelic-toc.php (working copy)
- @@ -235,7 +235,11 @@
- $toc .= "<li class=\"toc-level-$level\"><a rel=\"$rel\" href=\"$href\" title=\"$text\">$text</a></li>";
- }
- - global $id;
- + global $id, $post;
- +
- + if ( $post->comment_count ) #have_comments() won't work here
- + $toc .= '<li class="toc-level-2"><a rel="' . $rel . '" href="#comments" title="' . __( 'Comments' ) . '">' . __( 'Comments' ) . ' (' . $post->comment_count . ')</a></li>';
- +
- $tocID = ++$this->tocID;
- $tocID = "toc-$id-$tocID";
- $boxID = "$tocID-box";
Advertisement
 
                    Add Comment                
                
                        Please, Sign In to add comment                    
                 
                    