Re: Code cleanup and what about blank xprofile data? (Need dynamic link to profile)
When you say ‘left these blank’ then that can be checked by doing:
`
if (bp_get_member_profile_data( ‘field=instructor’ )) {
if (bp_get_member_profile_data( ‘field=instructor’ ) == ‘ Heiny’ )
‘do stuff’;
if (bp_get_member_profile_data( ‘field=instructor’ ) == ‘none’)
‘default selection has been saved’;
}else{
‘User has not visited profile and made a selection or simply re saved profile’;
}
`
However I may not be following what you are trying to do here fully. If you have used radio options then you can set one option as default i.e the ‘None’ which would be selected if profile simply re-saved, if the member hasn’t visited their profile then nothing should have been saved.
Think that work, at least it works running it quickly on a test install but I may have overlooked something crucial
With the markup please change the ‘div’ to paragraph tags, divs are a semantically null element their purpose is to aggregate and group structure into logical divisions, they must never be used to contain bare naked cdata.
Try and avoid using inline styling generally it’s a bad thing to style inline, add IDs or classes to the elements to use as styling hooks.
‘Strong’ is an a semantic element that is intended to confer special emphasis to a word or phrase if just needing to draw attention to a word then adding typographic conventions to it would be acceptable e.g <b> to embolden the characters, however in this instance you are probably better off using spans as a means of separating a section of the text to add distinct styling to.