Support

Account

Home Forums General Issues Page Link field content in a function Reply To: Page Link field content in a function

  • Sorry, I thought this was for the link field and not the page link field.

    The page link field doesn’t return link text and only returns the URL and you’d need to supply the text some other way.

    
    $link = get_field('your_link_field_name');
    if ($link) {
      echo '<a href="'.$link.'"><span>Button text</span></a>';
    }