Search Results for 'theme'
-
AuthorSearch Results
-
August 3, 2015 at 11:20 am #242708
In reply to: Extended Profile Character input limit
danbp
ParticipantCustom code goes to child-theme functions.php
Customizing BuddyPress needs a certain level of competence with PHP and the inner workings of BuddyPress & WordPress.
Please read https://codex.buddypress.org/developer/
and see also https://codex.wordpress.org/Functions_File_Explained
August 3, 2015 at 1:15 am #242702In reply to: Styling BuddyPress Login Widget
@mercime
Participant@jld142 Based on title of this topic, you only want to change the styling aka CSS. If that’s the case, you do not need to add any BP folders/files in your child theme. Just override the style in your theme’s style.css file or whatever stylesheet is enqueued in your premium theme.
If however, you want to change the markup or functionality in some form or the other, then you’d have to look at https://buddypress.trac.wordpress.org/browser/tags/2.3.2/src/bp-core/bp-core-widgets.php#L22 and make the fix in your child theme’s functions.php – no need to copy over any BP folder.
August 1, 2015 at 11:01 am #242669In reply to: Centralised Gallery for artist community
djsteveb
Participant@jordanboon0 – certainly there is more than one way to accomplish what you are proposing here.
My first thought upon reading this is is that you can create a “multi-user blog” with wordpress. Each new artist becomes a “contributor” or even “editor” upon sign up, and they can post a new gallery easily, then your admin(s) can choose what new galleries get published.
You go do all that with a single blog / wordpress install – and do it without buddypress, just make a cool custom author page for whichever theme you want to use.
There are many plugins and settings for things like front end uploads, post author profiles, wordpress gallery fancy stuff and all that.
You could also put buddypress into this mix and give your artists some extra social network stuff like private messages, groups and all that – however if you go with buddypress and and that layer to handle everything (without getting your users to submit posts / pages via standard wordpress) – then you have to get into a media plugin like rtmedia, mediapress, or – another one posted about a month ago.. anyhow – those media plugins are kind of their own “silos” – customizing how they work is not a few wp repo plugins away – and support for what you may want to do with them may be disappointing.
Of course you could take WP, add in BP if you really want the social layer, and still use the main site blog as kind of a “multi-user (or “group” blog) and do it that way.. you could get more complex and turn it into a multi-site install where each user get’s their own unique blog with gallery plugins – but moderation of posts and such with that setup may become more of a challenge – along with the extra headaches with running a multi blog network.
Anyhow – given the details you provided with your stated goals, I would forget about buddypress and multi-site – just install wordpress and do some searches in the wp-repo and themes section for “author pages”, “group blog” “post moderation” “front end uploads” and the various “Gallery” plugins – I think you can accomplish what you are going for pretty easily with lots of customization options.. without all the drawbacks and limitations of BP.
August 1, 2015 at 10:06 am #242668In reply to: thank you for registration page
Henry Wright
ModeratorTo customise the text, you can localise. See the Customizing Labels, Messages, and URLs article.
To add more to the confirmation page, you can use the
bp_before_registration_confirmedandbp_after_registration_confirmedhooks.To override the whole register.php template, see the Template Hierarchy article.
July 31, 2015 at 1:14 pm #242632Fiush
ParticipantYou can achieve this by using, ‘if ‘ and ‘else ‘ statement.
You can do that in theme/members/single/home.php
You can modify the code,
<?php locate_template( array( ‘members/single/member-header.php’ ), true ); ?>
To,
1) if user have profile field ‘male ‘ then
<?php locate_template( array( ‘members/single/member-header-male.php’ ), true ); ?>Else (eg: based on profile field selected,)
2) <?php locate_template( array( ‘members/single/member-header-female.php’ ), true ); ?>
Make sure to create two different templates in the same directory.
If this not the case, Henry can help you
July 31, 2015 at 10:06 am #242616In reply to: Add Icon behind User name in Activity Feed
peter-hamilton
ParticipantYou will have to make a buddypress template folder in your theme/child.
“entry.php” is the file you can add an icon, right after the following code which is the username/link.
<a href="<?php bp_activity_user_link(); ?>">July 30, 2015 at 11:46 pm #242601In reply to: Identifying profile fields by field ID
djsteveb
ParticipantI am interested in finding out what you come up with in regards to this.
I tried to use something like:
‘field’ => 2,
);(some info from https://codex.buddypress.org/themes/guides/displaying-extended-profile-fields-on-member-profiles/ )
to replace the actual names I was using in a page title template thing, and never got it to work – but I have no idea what I am doing – trying to franken-hack a bit of code provided by one person and replace the field names with field numbers so the code would work with a different site I was playing with – when I tried replacing the name with this field number thing it did not work – but again I don’t understand php nor bp stuff well enough to know if I just missed a character, or something else was needed, or the function isn’t working as it should.July 30, 2015 at 3:51 pm #242587danbp
ParticipantTo do that you need the xprofile field ID and the user ID.
Here an example to show a profile fied containing a fax number. The filed is called Fax (case sensitive).
Add this function to your child theme’s functions.php or better, into bp-custom.php
function my_directory() { if ( bp_is_active( 'xprofile' ) ) if ( $memberfax = xprofile_get_field_data( 'Fax', bp_get_member_user_id() ) ) : echo '<br/><div class="Fax">'; echo $memberfax; echo '</div>'; endif; } add_filter ( 'bp_directory_members_item', 'my_directory' );July 30, 2015 at 3:24 pm #242582In reply to: Add Icon behind User name in Activity Feed
danbp
ParticipantHi @alexsmoli,
you copy the original template file from:
buddypress/bp-templates/bp-legacy/buddypress/activity/entry.phpto the child theme to get this:
your-child/buddypress/activity/entry.phpReference
July 30, 2015 at 3:19 pm #242581In reply to: Modifying template files in child theme
danbp
ParticipantYou copy the original file from:
buddypress/bp-templates/bp-legacy/buddypress/members/members-loop.phpto the child to get this
your-child/buddypress/members/mmebers-loop.phpReference
July 30, 2015 at 9:13 am #242565In reply to: SEO title for activity posts
djsteveb
ParticipantIf I may suggest that instead you add to your robots.txt file some wildcard rules such as:
Disallow: *members/*activity*
Disallow: */activity/p/*as to where I think it may be possible to pull some info from the activity posts to create page titles and other meta stuff, most activity posts are going to be short in most cases, and having a bunch of new pages indexed (even properly with title and meta stuff) is likely to add little value to your site overall – and in fact might create a situation where a bulk of your site pages are considered “thin content” – which would hurt your seo more than any proper page titles will on activity pages.
Considering you are also asking about methods for adding meta keywords, I think you are looking for SEO help that is waaaaaaay outdated – unless you are going for different search engines aside from the big G, bing / yahoo for some reason – in which case my knowledge of the other spiders and their indexing methods is tiny.
Now if you are trying to get proper page titles on your “groups” and member profile pages, I think that would be a worthwhile effort.
Just a few random suggestions, I am not a BP dev or prof coder yet – others may have different advice.
I think that getting and using this info will be better / easier perhaps about WP 4.4 or whenever they include the REST API in the core – and then it should be easy peazy for themes to pull and use this info – not that it should be rocket science to do it now… however I have had no luck getting help with similar issues on other BP pages in the past.
It usually boils down to BP peeps saying that page title and meta stuff should be handled by your theme.. your theme devs will say they use the standard wp_title function (or something like that – which has been flipped around recently) – and that kind of stuff if you want it to be beyond what is “standard wordpress” should be handled by an SEO plugin… my experience with several SEO plugins has been that they will not get into all the BP “pseudo pages” for whatever reason, perhaps because a taxonomy is not registered for them, and that makes it more difficult.
Random thoughts for ya
July 30, 2015 at 8:01 am #242561In reply to: New user login info and forum display
danbp
ParticipantCustom code goes to bp-custom.php or child-theme’s functions.php
Code on second answer shows an usage example, it’s not the code you have to use.As you asked for register details, i thinked you want a resume of the registration with all mandatory xprofile fields information…
BP on a single install doesn’t sent a welcome email. This happens only on a MS install. But you add that manually. Read here:
July 30, 2015 at 3:28 am #242559In reply to: Removing Links from BP Profile Fields
djsteveb
ParticipantThis might be what you are looking for: https://codex.buddypress.org/themes/bp-custom-php/#examples
for detailed info, scroll up the page.
July 30, 2015 at 12:03 am #242555In reply to: Add dynamic menu link
danbp
ParticipantTry this:
// depending the theme Main Menu, somwhere near Home, About, etc function bpfr_custom_setup_nav( $items) { if ( is_user_logged_in() ) { $items = '<li><a href="'. bp_get_loggedin_user_link() .'activity/news-feed/">News feed</a></li>'; } return $items; } // 10 is the priority, 1 is the position in the menu add_filter( 'wp_nav_menu_items', 'bpfr_custom_setup_nav', 10, 1 );References:
https://codex.wordpress.org/Function_Reference/wp_get_nav_menu_itemsJuly 29, 2015 at 7:03 pm #242543In reply to: How Do I Display A Custom Profile Field?
danbp
ParticipantWhere do I put this and how do I make sure it doesn’t get removed
Custom code can be added to bp-custom.php
July 29, 2015 at 2:41 pm #242531In reply to: Stop Load More
bp-help
Participant@bigkahunaburger
You must be using a plugin, custom code, or theme that adds this because BP doesn’t automatically load more. I put a plugin on github over 2 years ago here: https://github.com/bphelp/bp-auto-load-activity
I have no idea if it even works anymore. You may want to check your plugins to see if you have it installed and activated. Brajesh from Buddydev also did a plugin that did this but I can’t remember the name of it right off. If its not one of these plugins it has to be either custom code or maybe built into your theme. Hope this helps, good luck!July 28, 2015 at 5:28 pm #242509In reply to: Moving the Buddypress Admin Bar menu
danbp
ParticipantJuly 28, 2015 at 5:01 pm #242504In reply to: User Profile fields hide on Profile page
danbp
Participantbiographical information, fax and maybe even addresses. These are WordPress or theme specific fields which are not visible on frontend profiles. BP doesn’t use them if you use the xtended profile component.
Anyway…Try this snippet, and use it to your need from within your child-theme functions.php
function remove_user_fields(){ // Print jQuery that removes unneeded elements ?> <script type="text/javascript"> jQuery(document).ready( function($) { // the magic goes here... var ids = ['#description', '#comment_shortcuts', '#color-picker']; // Check in page source for other ID's for (var i = 0; i < ids.length; i++) { $(ids[i]).closest('tr').remove(); } }); </script> <?php } add_action( 'admin_footer', 'remove_user_fields' );July 28, 2015 at 8:50 am #242487In reply to: Add dynamic menu link
danbp
ParticipantCodex reference:
Also, on the forum, several topics, with many snippets:
https://buddypress.org/support/search/bp_nav_menu/Here a working example, which add 2 external links on a profile.
function bpfr_custom_setup_nav() { if ( bp_is_active( 'xprofile' ) ) ?> <li><a href="<?php bp_members_directory_permalink(); ?>"><?php printf( __( 'All Members', 'buddypress' ) ); ?></a></li> <li><a href="http://buddypress.org" target="_blank" title="BP">BuddyPress</a></li> <?php } add_action( 'bp_member_options_nav', 'bpfr_custom_setup_nav' );July 28, 2015 at 8:33 am #242486danbp
Participantas you discovered already, the CSS trick is a poor solution.
Two solution are on hand.
A first one, which applies to all activity feeds.
Basically the below snippet handles globally the activties output. You simply remove the activity(ies) you don’t want to see from the list. Note that almost all activity types are listed.
Add it to child functions.php or to bp-custom.phpfunction demo_parse( $retval ) { // existing BP/bbP activities // remove the one you wont to see from that list $retval['action'] = ' activity_comment, activity_update, bbp_topic_create, bbp_reply_create, friendship_created, joined_group, last_activity, new_avatar, new_blog_post, new_member, updated_profile '; return $retval; } add_filter( 'bp_after_has_activities_parse_args', 'demo_parse' );Codex:
The second solution, is to use a child-theme with a modified activity loop. This let you handle finer condition for each user.
Read this tut how you can do that.
Codex:
July 27, 2015 at 7:27 pm #242480In reply to: [Resolved] Unable to crop Profile pictures
guidobrasil
ParticipantHi dan,
Thanks for your reply! I ended up taking away the kendo UI as I could reproduce the visual and functionality with Bootstrap, native in the worpress theme..
That was indeed the solution! 🙁
July 27, 2015 at 6:45 pm #242479In reply to: Custom login-form
Henry Wright
ModeratorThere will be plugins in the WordPress Plugin Directory that can do both of these things. Theme My Login won’t do exactly what you need but it’s a great plugin I’d recommend if you need to to bring the login page into your theme.
July 26, 2015 at 8:52 pm #242448In reply to: add whats new form to a member activity/friends tab
danbp
Participantuse this function
bp_get_template_part( 'activity/post-form' );Add this to bp-custom.php or child theme’s functions.php
function whats_new_my_friend() { if ( bp_is_user_friends_activity() ) : bp_get_template_part( 'activity/post-form' ); endif; } add_action( 'bp_before_member_body', 'whats_new_my_friend' );July 26, 2015 at 4:42 pm #242440In reply to: Using a theme just for BuddyPress
kjgbriggs
Participantchecking the Functions file, there is a huge amount of php requirements specified at the top (13 of them), I am guessing this will mess with me trying to make a child theme out of it.
On a lighter note.
The CSS files are included separately so I have the styles for BBPress and BuddyPress separated out for me.I have tried adding these to my custom CSS, but they don’t seem to change that much, just the overall placement of things.
July 26, 2015 at 1:34 pm #242436In reply to: Using a theme just for BuddyPress
djsteveb
Participant@kjgbriggs – just took a look at your oblivion thing you like – it appears to be the forums layout you are concerned with here – which may end up being more of a “bbpress” theme-ing issue – not so much buddypress… last I checked you can add “bbpress” as an auto-addon for buddypress – but if it’s not profiles and activity stream stuff – you may need to look up some “bbpress” specific theme things if you run into issues – not sure if they go over all that at bbpress dot org these days or not.. I have not checked those forums / docs in years.
-
AuthorSearch Results