This sounds a lot like
(What you enter as a custom JS function needs to be valid JS and not contain any placeholders)