Skip to:
Content
Pages
Categories
Search
Top
Bottom

Mulisite – How to Get a Users Site/Blog URL


  • myladeybugg
    Participant

    @myladeybugg

    In a multisite setup, when users are visiting a blog/site that is not theirs, I would like to display a link to “Visit My Blog” that takes them to that users “primary” blog – domain.com/user

    I have tried several different PHP variations, but none of them are correct. Each one either takes me to domain.com or domain.com/members/user

    Tried to input the PHP I have used but it doesn’t seem to save correctly. Maybe I am doing something wrong?

    I am using WP 3.5 with buddypress installed.

    Thanks

Viewing 6 replies - 1 through 6 (of 6 total)

  • EndlessRange
    Participant

    @endlessrange

    I’d love to follow this reply.


    Ben Hansen
    Participant

    @ubernaut

    yourdomain.top/members/yourusername/blogs/

    if your members page has a different name the url may also be different, ironically if your blogs page has a different name i think it’s still just “blogs”


    valuser
    Participant

    @valuser

    If i understood your query correctly (and i concede that it is very possible that i have not!) here is a piece of code that was passed on to me that worked.

    I had a div myveryownblog (you can put it anywhere) and when a user clicked on the image/text (make up your own image or have none) they were returned to their own blog. You could have it target blank if you wished.


    valuser
    Participant

    @valuser

    The above (code) should have read


    valuser
    Participant

    @valuser

    see the code at http://pastebin.com/W33QifgM.

    Sorry Mods, can you please clean up the previous mess all the best


    myladeybugg
    Participant

    @myladeybugg

    Thanks @valuser. The code seems to take me back to the main blog on the multisite, not the actual users blog, but I think this is close!

    Wish I was ok with PHP so I could mess around with the code to see if I could get it to work.

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Mulisite – How to Get a Users Site/Blog URL’ is closed to new replies.
Skip to toolbar