• I just setup a new site and would prefer to have the comments appear in a popup window instead of opening in the same window. It seems from other comments this happens by default, but its not happening on my site, it just opens in the same window.

    I see two different files, both popupcomments.php and comments.php that I can edit in WordPress. Where should I go in these files and what code should I insert to enable pop up comments?

Viewing 11 replies - 1 through 11 (of 11 total)
  • It’s not the default. It’s commented out by default. I’m not even sure where it is, you might check in header.php – see if you can find

    <?php //comments_popup_script(); // off by default ?>

    Uncomment it, should fix it.

    Thread Starter postmen

    (@postmen)

    I wasn’t able to find this in header.php or the two comment files. Anywhere else it can be?

    You’ll then have to add a comments-popup.php file to the theme as well as that code vkaryl told you to use. And also add the proper CSS for it in the style.css or whatever your theme’s CSS name is..

    ALSO, you’ll probably have to add the Call Tags….for the comments-popup within certain other files of your theme as well.. not sure about that …because I don’t use that option. Well, hardly anyone does really lol..

    You can find these in the default theme’s directory, then just add it to your’s and do some tweaking to fit your themes color scheme and what not..

    spencerp

    If I’m all wrong about this, someone please clarify it then or whatever…lol. =)

    Thread Starter postmen

    (@postmen)

    The comments-popup.php file is allready on the server in that theme folder.

    Anything else you are saying, sorry, I do not understand at all. Theres no other code anywhere in any of those files where I can simply add a tag or something to that extent to enable pop up comments??

    how do you enable scroll bars on the comments popup?

    Thread Starter postmen

    (@postmen)

    any other takers on how to do this?

    Find the file ‘header.php’ in your theme directory and open it in a text editor. Add the line:
    <?php comments_popup_script(); ?>
    just before the line
    </head>

    Save the edited ‘header.php’ file. Now you should have popup comments of the WordPress default size of 400×400 pixels. If you want to change the size of the popup comment window, try using the line:
    <?php comments_popup_script(450,500,''); ?>
    This will make a 450×500 pixel popup window. You can play with the figures to make it exactly the size you want.

    I’m not positive, but if you find this line within your comments.php file, and maye a couple others..

    Try changing this:
    <h3 id="comments"><?php comments_number('No Responses', 'One Response', '% Responses' );?> to “<?php the_title(); ?>”</h3>

    To this:
    <h3 id="comments"><?php comments_popup_link('No Responses', 'One Response', '% Responses' );?> to “<?php the_title(); ?>”</h3>

    Note: Changed The: comments_number to comments_popup_link.

    That SHOULD be correct…I hope lol. Maybe some other guru can tell ya better then hehe..

    spencerp

    actually for the new 1.5 default theme, you would put this code

    <?php comments_popup_script(); ?>

    right above this last two lines

    <?php wp_head(); ?>
    </head>

    that come right before the <body> tag.

    hope that helps.

    Is it me, or are people not really reading through the whole thread..?

    https://www.ads-software.com/support/topic/65297?replies=10#post-346539
    https://www.ads-software.com/support/topic/65297?replies=10#post-348385

    And I had already mentioned that before in other threads, just didn’t add it because vkaryl had already mentioned it in the second reply LoL!!

    spencerp

    I just dont have scroll bars on my comments when they popup… I have NO clue why.

Viewing 11 replies - 1 through 11 (of 11 total)
  • The topic ‘Enabling Pop Up Comments’ is closed to new replies.