Thank you, Jimmy. I overlooked that.
I inserted a quick cart on a test page, which works excactly as I like it to. I then tried to copy the code to the template page, but once I save the template page, the top part of the php code is not copied to all the other pages with the result, that on all pages everything after the quick cart is gone.
Is there a way, other than pasting the code to every single page, to get the template page to carry the php changes over to all pages?