Skip to:
Content
Pages
Categories
Search
Top
Bottom

Re: Make a different profile page for a special user

What did you actually try though Jenny?

For each profile display in the header.php there is the function:

bp_displayed_user_id()

This always returns the id of the current profile or user that is being viewed, you can check that by simply adding above the heading tag:

<?php echo bp_displayed_user_id() ?>

And you should see a numeric value returned which is that members ID

Now we know that it’s a simple case of writing an if conditional that carries as it’s primary query:

bp_displayed_user_id() == 1

If you’re not sure how to write PHP conditionals look through various theme files as there are countless examples of them (you’ll spot them by the fact they start with ‘if’ ) or check out the PHP docs php.net or google ‘php conditional statements’

If you are really still stuck post back and we’ll help further but conditionals are a useful bit of PHP coding to learn to write

Skip to toolbar