Forum Replies Created
-
In reply to: Custom logo in Buddypress 1.1
Well, letting an admin upload a logo is just the oppoite of keeping it simple. It’ll require some extra coding that the majority of users just won’t need or use. You can add a logo with just a few lines of CSS. Now that’s keeping it simple. I’d hazard a guess that stuff like that will never make it into core. Thankfully! Nobody really needs bloated software…
CSS is easy to learn and very intuitive as well. You can learn how to add your own logo within 3 minutes.
In reply to: CLASSIFIEDS COMPONENT newsHmm, that’s too bad. I need a classifieds plugin and I cannot/don’t want to use the blogs for that. They are being used for something different. Would you mind sharing your code with me so I could finish it off? That’d be great. No point in reinventing the wheel…
In reply to: Images allowedYou could write a plugin that does the embedding for you. You could provide your users with a shortcode that only takes the video url as an argument. Something like this:
[youtube url="http://youtube.com..."]Then you could set a width in the plugin code.
In reply to: Images allowedAs far as allowing certain tags in various components, have a look at the filters files in the various components folders. Pick the filter you want to get rid of (strip_tags for example) and then just add a remove_filter call to your functions.php file.
It’d be a very good idea to write your own function that adds some kind of security back in, though. You don’t want to leave your front door wide open…
In reply to: @user notation: A Feature Suggestionthreaded forums and such is kind of a different matter to using @username, erich. it’d be more like twitter, where you can see what has been said about you in one place rather than having to go to the forums, the wire or anything else.
In reply to: Editing NavigationThis is being handled with functions like these:
bp_core_new_nav_itembp_core_new_subnav_itembp_core_remove_nav_itembp_core_remove_subnav_itemAll of these functions (and a lot more) can be found in buddypress/bp-core.php. They are well documented and you can always have a look at the various core component how they use these functions.
To the admin bar you can add links like so:
function sv_add_link()
{
global $bp;
$link = '<li><a href="'. $bp->loggedin_user->domain . 'my-page" title="'. __( 'My Page') .'">'. __( 'My Page') .'</a></li>';
echo $link;
}
}
add_action( 'bp_adminbar_menus', 'sv_add_link' );Removing links also works with actions. Using the example from above you’d have to put this into your functions.php file:
remove_action( 'bp_adminbar_menus', 'sv_add_link' )You have to remove an action at the same priority as it has been added, so if you find an add_action call like this:
add_action( 'bp_adminbar_menus', 'sv_add_link' , 7 );you’d have to remove it with this:
remove_action( 'bp_adminbar_menus', 'sv_add_link' , 7 );Otherwise it won’t work.
Hope this helps you along a bit.
Well, personally I’d use VideoPress if I wanted to host my own videos/images. If I didn’t want to do that I’d probably write a YouTube/Vimeo/Flickr plugin.
Not a big fan of Kaltura. I tried it when I was toying with the idea of using Elgg, but back then it was clunky and unintuitive. Might have changed, though. That was about a year ago…
In reply to: Fighting SplogsI know what work I’d pick if the choice is between backbreaking rice fields, backbreaking shipyards and captcha solving. So, please support Bangladesh and leave your captchas intact
$1 per 1000-5000 captchas sounds like a pretty decent salary for the subcontinent…
In reply to: wp-signup.php is a blank pageaudiobookstef, you’re using free software, that is being made by now two core developers. Things take time and won’t be fixed within a few minutes.
The proper way to do this is to open up a ticket, just like Erich73, and then, in the meantime, use a redirect from wp-signup.php to your normal BP registration page, which is easy to do.
In reply to: How to add custom $usermeta to registrationI mean the registration/register.php file in your theme folder.
Found out that the code does work, btw. Was something else that caused it to break.
In reply to: How to Display the Post Time in ForumsYou need to put the var_dump stuff on its own line below your original date function

Just had a look at the forum functions and here’s what you need to do.
global $forum_template;
echo date("j", strtotime($forum_template->topic->topic_time));Let me know if it doesn’t work.
In reply to: How to Display the Post Time in ForumsHey,
actually, the j should only give you the day of the month and nothing more. If you want the day and the month you need to use “j M”.
The rest should work just as you wrote it if you have access to the variable $topic. Try this:
var_dump( $topic );and see what it outputs. If there’s nothing or NULL, then you’ll have to populate $topic first.
In reply to: how to change in top menu bar “Member” to “Analyst”They do make PoEdit for PC as well, you know?
In reply to: [Resolved] User RolesThese functions should sort you out, garynagel:
function sv_check_current_users_blog( $active_signup )
{
if( ! is_user_logged_in() )
return $active_signup;
if( current_user_can( 'YOUR_CAPABILITY' ) )
return $active_signup;
else
return 'none';
}
add_filter( 'wpmu_active_signup', 'sv_check_current_users_blog' );
function sv_remove_create_blog()
{
if( ! current_user_can( 'YOUR_CAPABILITY' ) )
bp_core_remove_subnav_item( 'blogs', 'create-a-blog' );
}
add_action( 'wp', 'sv_remove_create_blog' );You need to place these functions in your themes functions.php and replace YOUR_CAPABILITY with whatever capability you want to check for. You also need to have blog creation enabled. I’m using a slightly modified version of this to restrict users to maximum 1 blog, so I didn’t test this code at all.
The first function uses a filter to set the variable $active_signup to ‘none’ if the current user does not have a certain capability and for that user blog creation will be disabled. If the user has that capability the variable is not changed.
The second function removes the blog creation tab from the submenu. You probably need to modify the registration page as well.
Hope this helps.
In reply to: buddypress = Content AggregatorYou’ll have to write a plugin for that or modify an existing one.
In reply to: Set a default template for blogsit’s the name of the folder holding all your theme files
In reply to: Time line for BuddyPressHere ya go: https://buddypress.org/about/roadmap/
In reply to: New user blog page are not workingShould get you sorted:
https://buddypress.org/forums/topic/getting-a-consistent-look
In reply to: Make your own custom BuddyPress pageTry adding this function as well as the original from JJJ.
function example_page_setup_root_component()
{
bp_core_add_root_component( BP_EXAMPLE_SLUG );
}
add_action( 'plugins_loaded', 'example_page_setup_root_component', 2 );In reply to: NEW Avenue K9 BP 1.1 Theme ReleasedHey Mfgmk,
I know this is a bit late to reply to your comment from two weeks ago, but I just only read it now.
You shouldn’t copy functions.php from the parent theme to the child theme. It’ll throw errors. There’s another way to get rid of that third sidebar. Create an empty functions.php file in your child theme folder (all the functions from the parents functions.php will still work). In it you put this piece of code:
function sv_remove_sidebar()
{
unregister_sidebar( 'sidebar-4' );
}
add_action( 'admin_init', 'sv_remove_sidebar' );In the above example 4 is the ID of the sidebar. If a sidebar doesn’t have a specific name to identify it with WP will give it automatically a name like sidebar-ID, which is the case with the default parent theme. Then you set the sidebar you just unregistered to display:none in your CSS file and you should be all set, plus you didn’t touch any parent theme files.
In reply to: Forums and PHP memoryI guess so. I need that much just to run most of my single WP blogs.
it’s
bloginfo('stylesheet_url');Hey,
yep, you can do it that way.
Just fyi, get_header() also accepts one variable, $name. So if you write this in a template:
get_header('blog');then WP will look for a file called header-blog.php in your theme files and include that one instead your normal header.php file.
Have a look at the get_header function. Maybe you’re lucky and there’s a filter applied to $name. Then you could just write a function that does it all for you and you won’t even have to touch the header.php file in your parents theme.
have a look here: https://codex.buddypress.org/developer-docs/conditional-template-tags/
there’s some examples as well.
so you could do something like this:
if( bp_is_blog_page() ) {
include( 'blog-header.php' ); // include this file on blog pages
} elseif( bp_is_directory() ) {
include( 'dir-header.php' ); // include that file on directory pages
} else {
get_header(); // otherwise use our normal header
}Hey Erich,
in header.php look for this bit around line 47:
<input type="text" name="log" id="user_login" value="<?php _e( 'Username', 'buddypress' ) ?>" onfocus="if (this.value == '<?php _e( 'Username', 'buddypress' ) ?>') {this.value = '';}" onblur="if (this.value == '') {this.value = '<?php _e( 'Username', 'buddypress' ) ?>';}" />Use this instead:
<input type="text" name="log" id="user_login" value="" />Don’t forget to copy header.php into your child theme.