Is it possible just to set a singular field to use certain sanitize functions? For instance, I'd like to create a field for additional header elements in the Pages module and allow things like script tags but I don't want that in the body of the Page. I could set it on the module as a whole but I don't see a way to set it on the individual field.


  • If you are using the Pages module to save these values you can hook into the saving process using a Layout object (instead of an array). There is a post_process_saved_values($values) that you can implement which passes in an array of data to be saved:

    public function process_saved_values($values)
        // Put your code here...
        return $values;

    More on layouts as objects can be found here:

Sign In or Register to comment.