You took that out of context a bit. You should read the whole chapter. Christ was comparing the Pharisees and their belief in God through public acts to the real followers who profess their belief through private moments with God, directly. In that regard, you could basically say that "church" goes directly against this instruction from Christ by encouraging people to publicly express their faith as to convince others of their allegiance to God.
What Christ is saying is that your actions done publicly
When you give, keep it private.
When you pray, keep it private.
When you fast, keep it private.
No where in the Bible are we instructed to give with announcements (think Celebrities and their foundations). No where in the Bible are we instructed to pray publicly (think TV preachers and alter calls). No where in the Bible are we instructed to fact publicly (think believers that openly tell everyone when they are fasting). In other words, If you have to tell everyone you are a Christian/believer in God, then you are truly living the life of a believer.