It helps to inter-compare the gospels and letters to get a fuller picture. Here are the relevant verses:
Mt 5:13 Ye are the salt of the earth: but if the salt have lost his savour, wherewith shall it be salted? it is thenceforth good for nothing, but to be cast out, and to be trodden under foot of men.
Mr 9:49 For every one shall be salted with fire, and every sacrifice shall be salted with salt.
Mr 9:50 Salt is good: but if the salt have lost his saltness, wherewith will ye season it? Have salt in yourselves, and have peace one with another.
Lu 14:34 Salt is good: but if the salt have lost his savour, wherewith shall it be seasoned? It is neither fit for the land, nor yet for the dunghill; but men cast it out.
Col 4:6 Let your speech be alway with grace, seasoned with salt, that ye may know how ye ought to answer every man.
So, the first answer is that, according to Jesus and the common practice, salt can, indeed lose its savour (taste), and when this happens, such salt either goes on the land or the dunghill. It is cast out - ie. rejected for the table - and fit thereafter only to be 'trampled underfoot'.
The real question is 'what is this salt which Jesus says is a good thing and we are enjoined to have in ourselves?'. Firstly, it is to do with the sacrifice of ourselves (as in the Temple offerings, which were to be eaten) and the salting (flavouring) comes by the action of the fire. So, it is fire - ie. tribulation, life's sufferings and God's discipline - which produce the salt - the distinctive flavour of Christ - in us.
Also, salt and grace seem to be like 'two opposite sides of one coin' - so to speak. We know that grace is a gentle, sweet and kind thing, so salt must be astringent, stinging and speak of judgment and purging. So, we are to hold the two in the right balance in our dealings with unbelievers. To have salt and grace in oneself reminds us of our duty to stand for the gospel in its entirety, and not just speak about the 'nice bits'. However, since we are also enjoined to have peace with one another, scripture is saying that we should know when to go sparing in our use of the 'salt' and not be contentious.
There is one final point here and that is the obvious question of whether a Christian can lose his saltiness or even not possess it at all. I believe that this is indeed very true of many who profess to follow Jesus in these days, as I see in many instances the Christian world losing its saltiness and savour of salt in this world.
This is partly because of the increased rejection of the gospel by many people of the world, but it is also, sadly, because many Christians have lost their distinctive savour, too. The gospel has been 'watered down' and the doctrines of eternal life are being increasingly denied and replaced by new ones which no longer have to power to save.
This is a trajedy - and the Lord Jesus warned about it - on which the saints urgently need to see light and repent.