Forum Replies Created
-
If you are not familiar with building child themes in WordPress / BuddyPress – you should read this page before beginning:
https://codex.buddypress.org/extending-buddypress/building-a-buddypress-child-theme/
In reply to: How to include a php file?Where do you want to write the code – is it in a file in your child theme?
If the files are in the same directory, e.g. in your child theme folder, use something like:
locate_template( array( ‘myfile.php’ ), true )
It sounds though as though you are wanting to modify code in bp-default. You shouldn’t be modifying bp-default! All your changes should be in your child theme.
Before doing that – disable all your plugins back to just base WordPress
Can you post again now without problem?
If you can post ok, add your plugins back one at a time, testing until you find the one causing the problem.
it’s almost certainly a problem with your setup, and nothing to do with the core BuddyPress code.
As I suggested, check your bp-custom.php file first of all – it goes in the /plugins folder – did your developer put any functions in there that modify the behaviour of your site?
p.s. are you sure you are using vanilla BuddyPress – you (or developer) haven’t modified any of the core files?
In reply to: Remove Sitewide Activityhide_sitewide is a boolean, and in this line is being used to test whether an activity item has been marked as hidden or not – (it’s not a count @tom_taylor_85)
You should NOT be modifying the code there – that’s a core file, and you’ll run into problems when you upgrade if you’ve modified them. You’ve also changed the logic to say: if an item is marked as hidden get it to display – which is not what you want.
@bojanski – can you be clearer about what you mean by “remove sitewide activity tab” – do you mean you want to remove the main Activity page from the main nav bar?
If the latter – edit it out in header.php in your child theme.
In reply to: no user_activation_key insertedSteffy,
couple of thoughts –
Is your base WP install working correctly – does it send admin emails notification correctly (e.g. when a new user is added in WP backend)? If not, it is a base email configuration problem.
Have you got any additional plugins installed – one of our clients had a problem with a CAPTCHA plugin interfering with the activation process.
If neither of these, there are a number of threads on this site, dealign with the problem of activation emails not being sent – it might be worth searching those.
Roger
In reply to: Where to edit bp_activity_content_body()?No, not changing the core… Hooking functions / filters on to core actions. You would normally add these in your bp-custom.php or functions.php file. Check under documentation on this site for an intro to adding hook functions
In reply to: Bug in a member’s personal activity stream?“activity private” – was just a general thought if you’d added a plugin or other custom code.
As I said before, without detailed info about your configuration, and your theme – it’s going to be difficult for anyone to help you on this one.
Does it only affect one user, or more than one?
Can you simulate it on one machine / browser – i.e. try activity for 2 users – do they both work?
In reply to: Photography website. some uncertain thingsRe: 2
Probably best is to create a custom post type for the photos in your main blog.
Then add a bespoke front end form to let users upload photos (as new posts) in your main blog.
You can then use built in WP commenting, and off the shelf plugins for ratings and social sharing
In reply to: Instant Spam – How To Cut It Out ?@whitbyglennk – remember to search before posting – this thread has a comprehensive list of ideas for tackling spam:
https://buddypress.org/community/groups/how-to-and-troubleshooting/forum/topic/buddypress-spam/
In reply to: How can I make a company listing Directory?@rossagrant – drop me a line via http://21inspired.com if you’d like us to quote on the work
Alternatively, you might be able to pick up a freelance developer via the job board on this site
In reply to: How can I make a company listing Directory?There’s no off the shelf plugin for this, but it is possible to develop a solution (a lot more than a workaround!):
You could either do this by having a profile type for businesses, or developing a solution around custom posts / custom fields.
You’ll then have to build your own custom listing directory – not too hard! The BP profile directory already has a built in search that you could adapt / use directly.
We are building similar in a number of current BuddyPress client projects – and Poolie has also developed a very nice listings site based on BuddyPress: http://plazaa.de
In reply to: Bug in a member’s personal activity stream?It’s highly unlikely that it’s a bug in the activity stream – hundreds / thousands of sites run the BuddyPress activity stream without problem.
It’s almost certainly something wrong in your bespoke theme / bp-custom.php file.
Have you changed the theme since the second person carried out their activity? Does it show in the main site activity stream? Have you installed some privacy plugins, or has the member specified that their activity is private? Is the site hidden from search engines?
It’s impossible to provide much more help without a lot more information about your site configuration and the details of your theme code.
In reply to: Inconsistent translationNo… that line goes in your wp-config.php (as I said above). It doesn’t go in your template.
Are you using a different set of templates when someone is logged in?
Post the code used to create your header.php, and a screenshot of logged in vs. non-logged in. Without that, it is hard to give further support on this.
@hnla – DUPLICATE
this is the same as the thread that you started yesterday: https://buddypress.org/community/groups/localization/forum/topic/language-translation-without-manipulating-code-in-the-database/
In reply to: Javascript error with wp-fb autocnnectThis question would be better directed to the plugin developer (it’s not really a BuddyPress question)… they should be able to tell you what elements you need to have defined in your theme.
Note: We use wp-fb-autoconnect on one of our bespoke BuddyPress sites without problem.
In reply to: Individual page for user profileIf you want to display profile information in the sidebar, you should write your own custom profile loop – the following page gives you an introduction:
In reply to: Inconsistent translationDid you follow the instructions on this page: https://pl.buddypress.org/home/ ?
You may also want to make sure you have the language specified in your wp-config:
`
/**
* WordPress Localized Language, defaults to English.
*
* Change this to localize WordPress. A corresponding MO file for the chosen
* language must be installed to wp-content/languages. For example, install
* de.mo to wp-content/languages and set WPLANG to ‘de’ to enable German
* language support.
*/
define (‘WPLANG’, ‘fr_FR’);
`change to Polish in your case, of course!
In reply to: Where to add a custom js in the code?and, yes… you can write any php you like. Have a look through some of the includes in the default theme files (and also the use of locate_template )
We quite happily have a post form sitting in the header on every page in one of our sites. Not sure how this extends out to multisite, but don’t expect it would be a problem with secondary sites in subfolders. I don’t know if subdomains introduce any cross domain issues.
Check this review by Sarah Polly Plummer Gooding: http://wpmu.org/8-wordpress-plugins-that-enable-posting-and-editing-from-the-front-end/
Take a look at this page for details on writing your own custom activity loop – paying particular attention to the scope and filter options: https://codex.buddypress.org/developer-docs/custom-buddypress-loops/the-activity-stream-loop/
I’ve given you the function you need to get the current logged in user’s ID – you should use this in your call to bp_has_profile to initialise your profile loop for the correct user.
This is what you asked for in your help request.
The rest is fairly simple PHP programming
bp_loggedin_user_id()
It’s listed in the template tags section of the documentation on here. That should be the first place you look for bp functions.
In reply to: BP components no show in secondary blogsYes, you are right with your second assumption – they would typically click back to the main site through the little icon in the wp admin bar top right, or through a custom nav menu that you put in the secondary blogs.
It is better to use 2010 or other theme for the secondary blogs. Bp-default is intended for the maim site where bp is installed