So a client that I inherited has multiple PHP fields in each of their views.

I'd like to replace them. They're using PHP Code module as well as Views Customfield.

Would I have to write a custom views handler? Or is there some sort of alter that would allow me to basically replace each of these fields/data sources with my own information, without exposing a PHP filter to a user (even an admin user).

Basically I am trying to increase site security.


1 Answer 1


In cases like this, I usually use:


For pre-processing the views render array.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.