Hmmm…ok. I’m such a beginner. Hee hee hee. Ok, so I looked in the “View Source” on the page with the photo.
I found what looks similar to Kdriscoll’s post above, relating to folder (I use the “usr_profile_photo” subfolder)
I put this in the .onBeforeUpdate of my record, since the photo name field is just one of many fields, I cannot put this code in the .onDelete event, because the user profile record will never be completely deleted.
if WHAT_GOES_HERE? == true
{
$dir = "../_lib/img/usr_profile_photo";
$file = {PHOTO_FNM};
unlink($dir.'/'.$file);
};
I found what looks like the little “Delete this record” checkbox:
<input type=checkbox name="photo_fnm_limpa" value="" onclick="this.value = ''; if (this.checked){ this.value = 'S'};">
What is the proper syntax to use in my code snippet above, at the WHATGOESHERE? position , to check if the user has put a check in the “Delete this record” checkbox, so that I can delete the file on disk.