Skip to:
Content
Pages
Categories
Search
Top
Bottom

Forum Replies Created

Viewing 25 replies - 201 through 225 (of 572 total)
  • @sbrajesh

    Participant

    @hnla, completely agree about the trouble shooting steps. Since the code is spread in all the places(bp-custom.php/plugins/themes functions.php). It is really difficult sometime to find the culprit. Appreciate the steps you guys suggest and follow for the purpose. Let us have some feedback from Naved to find the error :)

    @sbrajesh

    Participant

    @hnla,
    Agree with you. and btw, the plugin predates the functionality in BP. At that time, there was no such redirection functionality in bp.
    @naved,
    yes, I will advise to with the route @hnla suggests.

    @sbrajesh

    Participant

    Can you confirm the the pretty permalink is working for pages, post. Just curious.
    Also, is it possible that you may link the site here, so we may check it in action ?

    @sbrajesh

    Participant

    thank you Bowe.
    Looking forward to that :)

    @sbrajesh

    Participant

    Hi Naved,
    try this plugin
    https://wordpress.org/extend/plugins/bp-redirect-to-profile/

    I had written it an year ago but it still works. Hope it helps. If it does not work. Please do let me know here.

    @sbrajesh

    Participant

    Thank you all.
    Sorry, I left yesterday as It was 5 AM in the morning here. Thanks for for all your suggestions. I am putting the update.
    @gregfielding , you are right Greg. I am including the auto delete on uploading new image.
    @modemlooper , yes I believe that can be modified. In this plugin I did not work to provide custom css, rather my point was, just upload and go .

    @mercime, @pcwriter
    Thanks to both of you for the suggestions. Including now.

    @djpaul, Thank for the suggestion Paul. I appreciate it.But that is not required :)
    @hnla no worries. When I publish a plugin as free, I do love to support them. So, the updates will follow today :). Btw, It is on Github, so always welcome to fork :)

    @sbrajesh

    Participant

    @mercime, thank you :)
    @naijaping thanks. That is easily achievable. If you are using Bp-default theme, you can use this code in your functions.php
    https://gist.github.com/1034872
    That should do it.

    @sbrajesh

    Participant

    @pcwriter
    Thanks Patrick. Will sure do that in update. It was something I did in an hour, so could not do much.
    btw, you can do your own css section using some code (here is an example)
    https://gist.github.com/1034853

    just putting that in functions.php or bp-custom.php and you can modify it :)

    @sbrajesh

    Participant

    Ok, Here you go
    https://github.com/sbrajesh/bp-custom-background-for-user-profile

    Please note, I have not added localization to the plugin yet. It will work with single/Multisite both. Once you activate the plugin, a user can visit his/her profile and change Background link will be present next to the change avatar. Hope that helps.

    @sbrajesh

    Participant

    Thanks. Let me clean the code and put the plugin in an hour here :)

    @sbrajesh

    Participant

    Hi, I have done something similar in one of my project. So, I may put the code here. Where do you want to show the background. Just on user profile page or for every page on the site when the user is logged in. I mean if you see twitter, It allows to setup the background for user profile, while on orkut, the theme changes sitewide. Just trying to understand your need.

    @sbrajesh

    Participant

    ooh, Since the thread was regarding cosmic buddy I misunderstood that. sorry.
    Isn’t Randy Candy a child theme of BuddyPress ? If yes, then you won’t need to update much. It should be some simple fix.

    @sbrajesh

    Participant

    @dubsel
    Get the update from here https://github.com/sbrajesh/cosmicbuddy
    It supports activities/reply.

    @sbrajesh

    Participant

    Hi,
    It seems you went in a little different direction. The
    `
    add_action( ‘wp’, ‘bp_activity_action_post_update’, 3 );
    `
    Is used for the time when javascript is disabled. Please have a look at bp-default/_inc/ajax.php and the line

    add_action(‘wp_ajax_post_update’,’bp_dtheme_post_update’);

    this is used by bp-default for posting update in ajax mode. I hope you can find something similar in your theme.

    @sbrajesh

    Participant

    Hi,
    Look for the post request. You will see some variable as action:”post_update” or something similar. Then look into your themes ajax.php(most probably in _inc/ajax.php) for a hook wp_ajax_{the action_name} , i.e. wp_ajax_post_update in this case. There will be a function attached to that. You can put your debug code in that function.

    rest is correct on your setup. The request will always go to wp-load.php, so that is right. Just investigate the attached function for debugging.

    @sbrajesh

    Participant

    No, That should not work. Reason, the $bp->displayed_user object is not initialized at the moment we are making changes.
    Instead check $displayed_user_id==$current_user_id

    @sbrajesh

    Participant

    @famous, you are right about that. searching multiple blogs is too costly on database if the posts are not cached in a global table. The unified search does not includes it because most of the sites do not use any sort of global post caching, and searching the posts on a network of say more than 20 blogs will be too much for a shared server to handle. I remember there is a plugin https://wordpress.org/extend/plugins/multisite-global-search/ which does global search.
    The problem is, It will put some real strain on database. if you still want to use it, you can extend the unified search with the above mentioned plugin.

    hope that helps.

    @sbrajesh

    Participant

    Put this code in bp-custom.php

    `

    add_action(“bp_setup_globals”,”my_default_tab”,8);

    function my_default_tab(){
    global $bp;
    global $displayed_user_id;

    $current_user_id=get_current_user_id();
    if(!$displayed_user_id)
    return;//if it is not profile return

    //a fix for table name before querying friendship
    $bp->friends->table_name = bp_core_get_table_prefix() . ‘bp_friends’;//a fix for friend check, because the table names are initialized too late

    if(friends_check_friendship( $current_user_id, $displayed_user_id ))
    define(“BP_DEFAULT_COMPONENT”,BP_ACTIVITY_SLUG);
    else
    define(“BP_DEFAULT_COMPONENT”,BP_XPROFILE_SLUG);
    }

    `
    That should do it.

    @sbrajesh

    Participant

    open bp-default/activity/post-form.php
    look for these lines
    `

    <option value="”>

    `
    It should be 43-45.
    remove it from the post from and user can only post to his profile.

    Btw, if you have child theme, then copy this file in your child theme and modify there. Otherwise the changes will be lost in another upgrade of buddypress.

    In reply to: Get Logged In Username

    @sbrajesh

    Participant

    No, you are doing it right then(assuming you are using some sort of PHp exec plugin for wordpress as wp will not allow including raw php). Doing independent page will need extra care to include wp-load.php and not a very good idea.

    in the current case, just double check that you have enabled BuddyPress plugin. I don’t see any other reason of the error.

    In reply to: Get Logged In Username

    @sbrajesh

    Participant

    well, In that case, some more questions will help.
    1. how do you create a buddypress page? from wordpress admin? from theme, have you added a new component as I don’t see other way to add a page in buddypress
    2. Is the page opened using wordpress/is coming inside wordpress (seems to me iT is not )
    3. Or is the page independent of wordpress, you are loading that page(php) directly inside the browser ?

    In reply to: Get Logged In Username

    @sbrajesh

    Participant

    are you calling that from bp-custom.php ? or your theme ?

    @sbrajesh

    Participant

    @all, great going, nice to see the movement :)
    @mercime, thanks :)
    @djpaul,
    just updated the xprofile template tags to cutdown the query for select/multiselect fields. Please have a look here https://trac.buddypress.org/ticket/3233

    @sbrajesh

    Participant

    Thanks @djpaul,
    Yes, I remember that. Just trying to bring it back as an option to the site admins and allow them to extend it.Going to put a patch later today for that.
    Re query: Yes, the query count is still applicable to bp trunk #4396. It is only in the case of multiselect box where the query is done for each item in the list. will look into that and put some patch.

    @doctordr, The front end posting capability is coming as part of wordpress upgrade in near future(hopefully). They are making the quickpress available to front end. checkout this ticket for details(It was dropped in 3.1 and let us hope it comes with 3.2)
    https://core.trac.wordpress.org/ticket/14966

    @sbrajesh

    Participant

    I am interested in improving the xprofile fields to allow developers to add new field types. currently we have a limited set of fields(say multiselect/checkbox etc). An example extension could be allowing to add an specializationn of select box with Country drop down which will save numerous times for many site owners. I am not sure if that needs to go in the core plugin, but certainly we need to add some action/filters in the core to make that happen. Also, currently, xprofile needs to improve the queries for fetching select field(My benchmark shows one query per item in the dropdown list of a field). So, if we have a field with 100 items in select menu on the edit profile/register page, It will do 100+ queries for that single field.

    If improving xprofile fields is still on the card, I will be very happy to work on it.

Viewing 25 replies - 201 through 225 (of 572 total)
Skip to toolbar