Re: Need to check if bp_profile_field_data() has data
I’m not really sure what you are trying to do with your code. Whereabouts are you trying to hide fields with no data? In the default theme profile-loop.php, fields without values are already not displayed.
As for quick fixes: You’ll need to replace ‘your-field-id’ with a variable that’s got the field id in it. You’ll also need to write valid PHP e.g. closing the PHP code before beginning your html. I’d steer clear of inline style definitions as well; the default BuddyPress theme comes with a comprehensive set of CSS files, and you’d be better augmenting these with style definitions.
Unfortunately, this forum isn’t really the appropriate place for PHP coding tutorials – You might be better reading up on PHP before attempting to modify the theme templates in any depth.