Which Files Create the Page Titles 'Site-Wide-Activity', 'Members' and 'Groups'?
-
Which files create the page titles ‘Site-Wide-Activity’, ‘Members’ and ‘Groups’?
http://1a-spielwiese.de/wp-content/uploads/2014/10/Page-Titles.jpg
And how can I change or delete them?
-
the best, fastest and easiest way to check for a word used in buddypress is to open the pot file, where you find it aside the file(s) and line number where it is used.
Thank you, @danbp!
I opened the .pot-file finally not with poedit (there I didn’t found any aside-information), rather with an editor. There I got the information, that I can find, e.g., ‘Site-Wide-Activity’ in the buddypress/bp-activity/bp-activity-loader.php.
I changed ‘Site-Wide-Activity’ into ‘Neuigkeiten aus dem 1a-Spielwiese-Netzwerk’ – and it works: đ
http://1a-spielwiese.de/activity/
I changed the original file at it’s original place. – Would it work with my child-theme-folder as well? If yes: Where I would have to place my bp-activity-loader.php-Copy?
On the highest level of my child-theme-folder? Inside my buddypress-folder there or inside my buddypress/bp-activity-folder there? Or anywhere else?
Changing words with the translation file is best practice, so you haven’t to modify anything in a core file.
If you want to modify template files, you do that with a child-theme and by respecting the same directory structure as in bp-legacy/buddypress/…/file_name.php:
wp-content/themes/your_child_theme/buddypress/…/file_name.php
1000 times explained and detailed on this forum and documented on Codex.
‘Members’ I found in the buddypress/bp-members/bp-members-loader.php
The relevant line there is:
'directory_title' => _x( 'members', 'component directory title', 'buddypress' ),
With
' '
(instead of ‘members’) I’m able to delete the text; but''
(instead of ‘members’) suprisingly produces ‘Mitglieder Verzeichnis’ (in German!) in des Frontend…—
And the page title ‘groups’ is in the buddypress/bp-groups/bp-groups-loader.php
@danbp / https://buddypress.org/support/topic/which-files-create-the-page-titles-site-wide-activity-members-and-groups/#post-203962
‘by respecting the same directory structure as in bp-legacy/buddypress/âŠ/file_name.php:’
But the EXAMPLE-loader.php-files are not inside the bp-legacy-folder!
The structure is:
- on the one hand, e.g.: buddypress/bp-actitvity/bp-activity-loader.php
- and on the other hand: buddypress/bp-legacy/buddypress/bp-activity – but there isn’t any bp-activity-loader.php
Within my child-theme-folder the equivalent for buddypress/bp-legacy/buddypress/bp-activity is simply buddypress/bp-activity (!) – or, as you explained there, regarding the members-loop.php:
wp-content/plugins/buddypress/bp-templates/bp-legacy/buddypress/members/members-loop.php
To modify this file, you make a copy of it and put it into your child-theme
/your-child-theme/buddypress/members/members-loop.phpTherefore, placing the my bp-activity-loader.php inside my reddle-child/buddypress/bp-activity-folder would not ‘respecting the same directory structure’, rather changing it!
this is bp jargon… and i wrote
bp-loader.php is a core file
and a template file is a file in or from bp-legacy/buddypress/Therefore, placing the my bp-activity-loader.php inside my reddle-child/buddypress/bp-activity-folder would not ârespecting the same directory structureâ, rather changing it!
Nobody told you to put bp-loader in the child theme !
If you need to modify a core code, you generally use a custom function to add/remove/modificate the originla function, with help of a action hook for example. Or other technique. This depends for what and where to apply a modification.
@danbp / https://buddypress.org/support/topic/which-files-create-the-page-titles-site-wide-activity-members-and-groups/#post-203971:
Nobody told you to put bp-loader in the child theme !
My question was:
Where I would have to place my bp-activity-loader.php-Copy?
And your answer was:
If you want to modify template files, you do that with a child-theme and by respecting the same directory structure
So, if your answer was not an answer on my question – what would be then the answer on my question?
—–
However:
Changing words with the translation file is best practice, so you havenât to modify anything in a core file.
Of course, this would work; but I would not call this a ‘best practice’ – because ‘Neuigkeiten aus dem 1a-Spielwiese-Netzwerk’ is clearly not an a translation of ‘activity’.
And anyway: The page title ‘Members’ and ‘Groups’ are correctly translate within the Decker-translation, which I use:
http://1a-spielwiese.de/wp-content/uploads/2014/10/Members-Page-Title_translated.jpg
and
http://1a-spielwiese.de/wp-content/uploads/2014/10/Groups-Page-Title_translated.jpgNevertheless I got displayed in the Frontend ‘Members’ (not: ‘Mitglieder’) and ‘Groups’ (not: ‘Gruppen’), before I changed the core files today:
http://1a-spielwiese.de/wp-content/uploads/2014/10/Page-Titles.jpg
And other users have the same problem:
Ich möchte die Seite gerne komplett in deutsch gestalten, aber egal welche “.mo” Dateien ich ins buddypress/plugin/language Verzeichnis lade, alles ist auf deutsch, nur nicht die Ăberschriften “Sitewide Activity” “Members” etc.
http://forum.wpde.org/buddypress/58502-bp-1-1-sprache-nicht-komplett-deutsch-2.html#post575160 (09.09.2014, 20:52 h)
If you are referring to the directory pages – “Activity”, “Members”, “Groups”, then simply edit the page title under the “Pages” menu in the WP dashboard.
“then simply edit the page title under the âPagesâ menu in the WP dashboard.
No, this does not work:
My page titles there were – already before changing the bp-activity-loader.php and the bp-groups-loader.php – (and are there still) ‘Neuigkeiten’ and ‘Gruppen’:
http://1a-spielwiese.de/wp-content/uploads/2014/10/WP-Seiten-Titel.jpg
und
http://1a-spielwiese.de/wp-content/uploads/2014/10/Neuigkeiten.jpgNevertheless, in the frontend was displayed ‘Side-Wide Activities’ and ‘Groups’:
http://1a-spielwiese.de/wp-content/uploads/2014/10/Page-Titles.jpg
And there is displayed now ‘Gruppen’ – because I changed it inside the bp-groups-loader.php.
And it is displayed ‘Neuigkeiten aus dem 1a-Spielwiese-Netzwerke’ (and not only ‘Neuigkeiten’) – because the bp-activity-loader.php (and not the WP Admin-Panel) is decisive.
Therefore again:
How can I prevent, that my changed bp-activity-loader.php and bp-group-loader.php files will be re-changed through the next BuddyPress-Update? – Would it work to place them somewhere into my child-theme-folder? And if so: Where precisely inside that folder I would have to place them?
- The topic ‘Which Files Create the Page Titles 'Site-Wide-Activity', 'Members' and 'Groups'?’ is closed to new replies.