How about helping us help you - when you try to splice this code snippet in the proper place, what does or does not happen?
Please, be detailed.
remove the edited by if an admin or mod edits a post in the ubb_edit.cgi
Yes, I can see that, but what is and is not happening?
Details, please.
As CC said, you're going to have to provide some more details, but right off I see you're using both $profileinfo[8] and $user_profile[8] to check the status field, which may be causing you problems. Also, did you remember to chomp the value you're checking on?