Archives

Allow HTML in User Descriptions

By default, WordPress will remove any HTMl from the user bio field on the edit user/profile screen.

It’s very easy to stop WordPress from doing this

remove_filter( 'pre_user_description', 'wp_filter_kses' );

However, you probably don’t want to leave it at that, as users could then add any code (iframes, scripts, etc.) and it wouldn’t be removed.

add_filter( 'pre_user_description', 'wp_filter_post_kses' );