[ticket/11956] Move code that hides dropdowns to assets

PHPBB3-11956