Appending script tags to head, not body