Skip to:
Content
Pages
Categories
Search
Top
Bottom

[Resolved] Locating comments.php for editting

  • Avatar of Sparkey
    Sparkey
    Participant

    @sparkey

    I have searched all day, I give up. I am trying to do a simple edit on the blog comments area.

    I am running WP 3.0.1 and BP 1.2.7 and child theme My BuddyPress 1.0

    The line that I am working on is:

    <?php printf( __('You must be logged in to post a comment.’, ‘buddypress’), wp_login_url( get_permalink() ) ); ?>

    I have located a bunch of comment files but the one I believe that I should be editting is:
    wp-content/plugins/bubbypress/bp-themes/bp-default/comments.php

    I have tried editting comments.php through the backend editor also, I have completely deleted the line that I am trying to edit and its still there so I figure I must be in the wrong place.

    I did find this line in a different place earlier this morning but deleting the line there didn’t help either, I don’t remember where that was now, these are the only two places that have the line.

    I’m sure its simple and I have probably thought too hard and too long, to find it now. Can you tell I’m an amateur?

    Any ideas? Thanks in advance

Viewing 15 replies - 1 through 15 (of 15 total)
  • Avatar of Sparkey
    Sparkey
    Participant

    @sparkey

    I tried a test and edited comments.php through the backend theme editor, wordpress agrees with me, the file that it is editing is:
    wp-content/plugins/bubbypress/bp-themes/bp-default/comments.php

    but editing that file doesn’t affect the blog comments.

    I’m sure this is just the standard WP blog if I understand all this correctly, I haven’t activated multiple blogs – I don’t seem to be using the BP blogs loop directory stuff at all.

    Thanks

    Avatar of Virtuali
    Virtuali
    Participant

    @gunju2221

    Could you put what you want in a nutshell for me? :)

    Avatar of Sparkey
    Sparkey
    Participant

    @sparkey

    Where should I be looking for the comments.php file if not in the bp default theme.

    Or maybe the page is constructed with functions?

    I can’t find where some of these functions are defined either:’bp_before_blog_comment_form’

    but I think that is the avatar or something and is probably not what I need but it might help if I knew where it was defined.

    Thanks

    Avatar of danbpfr
    danbpfr
    Participant

    @chouf1

    The line you’re looking for is in:

    bp-themes/bp-default/functions.php -> line 538

    Avatar of Sparkey
    Sparkey
    Participant

    @sparkey

    @Chouf1

    Thank you but… that file only goes up to line 360, I just double checked at :

    http://trac.buddypress.org/browser/tags/1.2.7/bp-themes/bp-default/functions.php

    Avatar of Sparkey
    Sparkey
    Participant

    @sparkey

    So.. What are the rules on bumping here?

    Avatar of danbpfr
    danbpfr
    Participant

    @chouf1

    Sorry, i didn’t see you’re using 1.2.7….
    The line you search is this one
    http://trac.buddypress.org/browser/tags/1.2.7/bp-themes/bp-default/comments.php#L100
    note that comments.php is the only file where this line exist.
    if you search for specific things, this is a good starting point:

    http://etivite.com/groups/buddypress/hooks/

    Avatar of Hugo
    Hugo
    Moderator

    @hnla

    What are the rules on bumping here?

    Try and wait ~24 hours before bumping

    Avatar of Virtuali
    Virtuali
    Participant

    @gunju2221

    Sorry for not responding.

    Your just looking for the Comments Function on your theme?

    There is most likely a “comments.php” in your theme folder.

    Avatar of Sparkey
    Sparkey
    Participant

    @sparkey

    Thank you guys so much for getting back to me. I really want to straighten out this page, our visitors are commenting all over the place or not at all.

    @Chouf1 Yes, that is line is what I am changing, but the output doesn’t change.

    @Virtuali Yes, that is the location that I have been working on, there was no comments.php in my child theme folder so I was editing the one in bp-default, when editing that didn’t change the output, I added a comments.php file to my child theme, still no change to the output. I tested the backend theme editor, when I added the comments.php to the child theme that is the one that it started editing, where before it had been edting the comments.php in the bp-default folder.

    Maybe there is some kind of cache system I can’t find, I know in Joomla when I get this frustrated, I remember the built in cache, I have cntl-f5ed it a couple times.?????

    Avatar of danbpfr
    danbpfr
    Participant

    @chouf1

    By default, there is no cache system. It’s not possible that the output doesn’t change….except if your changes are not saved.
    Work on local ! Do the text change in comments.php of your child theme and upload it via FTP
    Refresh your browser history (ctrl+F5) and see if the change is done.

    Avatar of Sparkey
    Sparkey
    Participant

    @sparkey

    Cool at least I’m surer about that whole cache thing, I haven’t added any cacheing.

    And yes I work on local as you say, that is just what I have been doing.

    I only tried the backend editor to see if it agreed with my file location.

    Well I seem to be doing everything right but no change to output.

    Avatar of Sparkey
    Sparkey
    Participant

    @sparkey

    I think I got it, it is maybe a plugin that I am using:

    “BuddyPress Activity Stream as Blog Comments”

    I haven’t found the place to edit yet but I have a new place to search!

    Avatar of @mercime
    @mercime
    Keymaster

    @mercime

    == I think I got it, it is maybe a plugin that I am using: “BuddyPress Activity Stream as Blog Comments” ==

    Glad you found the real source and sharing the info. I didn’t expect that and I guess neither did @chouf1 @gunju2221 :-)

    Avatar of Sparkey
    Sparkey
    Participant

    @sparkey

    Yep, thats it. I didn’t follow the authors instructions, well until I wanted to edit the comment section it wasn’t necessary, I guess. Below is what the plugin author says:

    “If needed: Copy and modified the /theme/activitycomments/ files to your default theme (important to keep the folder activitycomments into the root default theme directory)”

    So I added the “activitycomments” folder to my child theme, and I am editting the file “activitycomments/blogactivity-comments.php”

    <?php
    if ( post_password_required() ) :
    echo ‘

    ‘ . __(‘Password Protected’, ‘buddypress’) . ‘

    ‘;
    echo ‘

    ‘ . __(‘Enter the password to view comments.’, ‘buddypress’) . ‘

    ‘;
    return;
    endif;

    if ( is_page() && !have_comments() && !comments_open() && !pings_open() )
    return;
    ?>

    <?php printf( __('You must be logged in to post a comment.’, ‘buddypress’), wp_login_url( get_permalink() ) ); ?>

    Thanks everybody for the help ;-)

Viewing 15 replies - 1 through 15 (of 15 total)

The topic ‘[Resolved] Locating comments.php for editting’ is closed to new replies.