I want a more professional version of this snippet:
[login to view URL]
In a textarea I want to give the users to tag users or words using @ (for users) and/or # for words. But must works only if before @ or # there is a white space to avoid confists with (eg) emails.
Users and Tags will be in a list of values from 2 different tables eg table_users and table_tags.
After form submission and before saving in database username and words must be prefixed with a standard link and a dynamic fields (userid or tagid).
You don't need to save in database. Just echo the replaced text.