@Edent Your example doesn't work outside of the box? I *think* this would've worked the last time I used PHP? Could it be that the problem is rather on the browser side and that it's waiting for the </head> closure?
@Edent Ah I understand better what's happening now, but don't have a solution, sorry :)