Skip to:
Content
Pages
Categories
Search
Top
Bottom

ive got cover photos for profiles working but…

  • @mcpeanut

    Participant

    Hi i have found this solution to add a cover photo on a users profile using the answer and plugin linked in this post.

    https://buddypress.org/support/topic/cover-photos-for-profiles/

    it works really well apart from one thing, the user can only see his own cover photo when viewing his own profile where as i would like for other users to see the cover photos when visiting someone elses profiles! any ideas what extra code i would need to add to make them show to other users?

Viewing 5 replies - 1 through 5 (of 5 total)
  • @mcpeanut

    Participant

    sorry im not bumping this post as its already at the top i forgot to mention @timvango who originally gave the answer in the linked thread to see if he could help shed some light on this, oh and @peter-hamilton who has also managed to do this already on his website, ty for helping in advance guys if you can.

    @mcpeanut

    Participant

    ok this is still at the top so im not bumping it again lol, this is just to let you know ive managed to fix the problem anyhows, it was sort of staring me in the face.

    incase anyone else is wanting to achieve this please click the link to the other post as mentioned above and change the code to this.

    <style type="text/css">
    body.is-user-profile div#item-header{
    background:url(<?php echo $image_url;?>);
    width: 100%;
    background-size: 100%;
    background-repeat: no-repeat;
    }
    </style>

    turns out all i had to do was add div#item-header to body.is-user-profile for it to work.

    Sometimes i need to give myself a shlaap and drink some more coffee when im up all night trying to add a new feature, lack of sleep can do this too you! haha

    @peter-hamilton

    Participant

    Nice one mate, you figured it out in a few hours, took me about 6 weeks.

    It is quite a nifty feature when done correct, hope you will share your URL when you ready so we can have a look.

    P.H.

    @peter-hamilton

    Participant

    And I am prepping a small tutorial on how to do the same for groups, should be ready later today or tomorrow.

    It is similar to the profile header for members, which is actually based on the group custom background plugin.

    Both member and group header plugins have been hardcoded in my child theme to minimize calls to my plugin folder, and together only require two files and a few lines in functions.php.

    I am almost finished with my theme/site, have a look on my progress, response is very motivating, even negative is helpful.

    onlijn.com/my-profile

    @youmin

    Participant

    Awesome and welcome move by you both,

    Waiting for tutorial of your works.

    Than you,

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘ive got cover photos for profiles working but…’ is closed to new replies.
Skip to toolbar