Skip to:
Content
Pages
Categories
Search
Top
Bottom

Activity Permalink/URL function

  • Avatar of @ChrisClayton
    @ChrisClayton
    Participant

    @chrisclayton

    Hey, i hope someone can help me out here…
    to explain, i am editing my entry.php – as the default doesnt really mingle with my theme.

    i am using the
    ‘ ago’
    function to get the posted date, but i want to link the date the the activity permalink.

    is their a function to call the activity url?

    i hope im making sense?

Viewing 5 replies - 1 through 5 (of 5 total)
  • Avatar of r-a-y
    r-a-y
    Moderator

    @r-a-y

    bp_activity_get_permalink() might help you there.

    Avatar of @ChrisClayton
    @ChrisClayton
    Participant

    @chrisclayton

    Thanks alot @r-a-y, the amount of times you have directly and indirectly helped me out.

    i tried this -

    But it stripped out the item id.

    maybe im doing something wrong? in my entry.php i put

    `<a href="
    “> ago ยท `

    Avatar of @ChrisClayton
    @ChrisClayton
    Participant

    @chrisclayton

    hrm, i got it working by hacking it and using “

    i guess this will work for now, it accomplishes what i need.

    `<a href="/activity/p/”> ago · `

    is their a better way?

    Avatar of r-a-y
    r-a-y
    Moderator

    @r-a-y

    You need to pass the activity ID in bp_activity_get_permalink().

    `bp_activity_get_permalink( bp_get_activity_id() )`

    Avatar of @ChrisClayton
    @ChrisClayton
    Participant

    @chrisclayton

    That makes a lot more sense. thanks @r-a-y

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

You must be logged in to reply to this topic.