This is simply not possible. Note, the developers guide mentions you have only three options for script tags to fire:
Is there a particular reason you need the code in the after_header? There may be other approaches you can take to achieve what you need.
When you tried separating the script in the head and the button in the after_header, are you sure the script is not firing at all, or is it that you are unable to select the button? It may be due to the way the Ember runloop is.