Skip to:
Content
Pages
Categories
Search
Top
Bottom

Help need on conditional taq

  • Profile photo of Marc P Gangmei
    Marc P Gangmei
    Participant

    @weblogian

    I want to display member feed url from the profile field “Feed” else if not available my site feed url as default

    Here a sample(not working):
    <?php if(bp_profile_field_data($field->ID, ‘Feed’, $single = true)){echo bp_profile_field_data( ‘field=Feed&user_id=’ . bp_get_member_user_id() ) else{bloginfo(‘url’); echo "/feed";} ?>

    Can anyone help me?

Viewing 2 replies - 1 through 2 (of 2 total)
  • Profile photo of Marc P Gangmei
    Marc P Gangmei
    Participant

    @weblogian

    coming close
    <?php $data=bp_profile_field_data( 'field=Feed&user_id=' . bp_get_member_user_id() );

    if(!empty($data))

    {

    else

    echo ‘Fill up your feed url in your profile';

    } ?>

    Profile photo of Marc P Gangmei
    Marc P Gangmei
    Participant

    @weblogian

    Oh I got it
    You can now see the member ‘s external blog link and latest update in the member directory page
    http://blogcastor.com/members/

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Help need on conditional taq’ is closed to new replies.
Skip to toolbar