18 And he said to them, Are you also (the disciples) so lacking in understanding? Do you not understand that whatever goes into a man from outside (such as what he eats) cannot morally defile him whether or not he performs the man made tradition of ritual hand washing?

19 Why? Because food does not go into his heart, but into his stomach, from there, it travels into his intestines, and is then purged from the body.

Note: The phrase "(In saying this, Jesus declared all foods 'clean')" [NIV] or "(Thus He declared all foods clean)" [NAS] does not appear in the underlying Greek text (and this English phrase DOES NOT appear in the KJV at all).

It is an editorial comment placed there by Bible editors (see Wiki reference below) to make it say what they want it to say, similar to the NIV editors at Colossians 2:17 where they changed the verb tense of the underlying Greek so as to make it agree with their doctrine (they admitted that in their work "The Making of a new Translation"). For a more detailed discussion, see our "What About Scriptures" teaching on Colossians 2:16-17 elsewhere on this website.

If in fact at this point Yeshua was declaring "all foods clean", there are at least three things to take into account. In the end, the evidence is overwhelming that Yeshua, in context in Mark 7, is dealing with the Pharisee complaint about the disciples not observing the tradition of the ritual hand washing before partaking of their meal.

A more detailed look at this passage will be available (and linked here when it is) in the near future since this is one of the "What About Scriptures".

See paragraph 2 and 3 of this link:
Wikipedia

The title of the section is:
Law-related passages with disputed interpretation
Paragraph two begins with:
"Some have interpreted the NRSV's parenthetical statement:..."

Here you will see where the error comes from and what the Scholarly consensus is.