Light also is a positive image: the world is in darkness and Jesus’s followers are to be a light in that darkness. A “light in the darkness” is part of the messianic age, the suffering servant was to be a “light in the darkness.” Zechariah alludes to this in Luke 1:79, his son John will shine a light for those living in the darkness. They are in the dark because they live “in the shadow of death.” The Gospel of John describes Jesus as the “true light that gives light to everyone” (John 1:9) which overcomes the darkness (1:4-5).
Jesus offers two metaphors for the way his disciples were to be light in the world, a city and a lamp. First, a city on a hill cannot be hidden. it can be seen from a distance and any light from that city will be seen clearly in the darkness. Jeremias (Parables, 217) understands the saying as a word of comfort for the disciples, the “citizens of the … eschatological city of God … whose light streams through the night needing no human efforts.” Second, when a lamp lit, it was normally placed on a stand or in a niche in the wall so the light can illuminate the whole room. In makes no sense to hide an oil lamp under a basket, the point of a lamp is to shine light in the darkness.
The point of the two illustrations is that it is impossible for the Christ-follower to hide their light, and even if they could manage to hide their light, it makes no sense to do so since their entire purpose is “being a light.”
If the “Salt of the Land” referred to the disciples as a preserving agent within Judaism (as opposed to the Pharisees), then “Light of the World” refers to the function of Israel as the light to the Gentiles. Jesus uses κόσμος rather than γῆ, so the whole world (Jew and Gentile) is in view rather than just the Land of Israel.
Pennington points out that Scot McKnight is unique in his assertion the two words refer to different things. He argues they are in parallelism and therefore have the same reference. Pennington, Sermon on the Mount, 164, note 74. Late he says “both the salt and light metaphors are communicating the same idea, that Jesus’s disciples are not the heralds of the new and lasting covenant being effected by Jesus” (p. 165). While it is true Jesus’s disciples are heralds of the new covenant, is that what this passage is actually saying? He argues that salt and light overlap in the area of covenant, salt used with bread to conclude a covenant agreement, and light as associated with the messianic age of the new covenant.
Israel was supposed be so devoted to God, living out a wise lifestyle, that the nations would see them and be attracted to God. They were the “light of the world” in the Old Testament, but they failed to be devoted to the Law and failed to live out a wise life and rarely attracted Gentiles to the God of Israel. There are some examples of Gentiles honoring the God of Israel (Nebuchadnezzar, for example, perhaps Nehemiah, Esther and Mordecai), but for the most part Israel did not act as the “light to the world.” Ultimately, the “light to the whole world” is the messiah, especially in Isaiah 9:2, a passage quoted by Matthew 4:16 (cf., Isaiah 42:6, 9).
Finally, the followers of Jesus are to let their light shine in the world so that people will see this and glorify the Father. This too was supposed to be a function of Israel in the Old Covenant (Deut 4:5-8). If Israel is obedient to the Law, then the nations will see this and consider Israel to be a great and wise nation.
The followers of Jesus are to be the preserving agent in their culture; they are still the only light in this dark world, the only want that light can be seen is if it is active in the world in some real and tangible way. Good works is “a translation of the Jewish מַעֲשִׂים טֹובִים, the thought is of those demands of God that are not legally prescribed by the Torah, such as especially works of charity and alms giving” (Luz, Matthew 1-7, 208).
There are many examples of Christians who live out their faith in a way which benefits the whole culture and demonstrate to the culture the light of Jesus Christ. Some Christians live out a Christ-like lifestyle in a way which makes life better, healthy, etc. so that people are attracted to the Light.
But there are far too many Christians who are not unlike the Pharisees in the first century, so committed to a narrow way of thinking they are no longer benefiting their culture and they are more like a dim lamp underneath a basket!

Although the phrase does not appear in Matthew, in Luke 21:24 Jesus says “Jerusalem will be trampled underfoot by the Gentiles” (using the cognate verb πατέω). Revelation 11:2 is a possible allusion to this verse, the Gentiles will trample (πατέω) Jerusalem for 42 months. But Gentiles trampling Jerusalem appears in clear eschatological texts the Hebrew Bible as well. For example, in Daniel 8:13 Daniel asks how long the sanctuary and host will be “trampled underfoot?” Although it is not the same word as Matthew 5:13, the LXX uses a related verb, συμπατέω. Daniel 8 refers to the desecration of the Temple prior to the Maccabean revolt, but Jesus uses the language of Daniel 9:27 to predict the coming fall of Jerusalem (Matt 24:15).

Who would persecute someone for doing acts of justice for the poor and helpless? In the immediate context, the Pharisees will challenge Jesus for his ongoing actions towards the underclass in Galilee. He touches a leper to heal him (Matt 8:1-4), even though the leper was “unclean” and forbidden to worship at the temple. He heals the servant a centurion’s servant (8:5-13). Even if the centurion was a God-Fearing gentile, he would not be permitted to enter the court of the men and worship at the Temple. Jesus eats with “tax collectors, prostitutes and other sinners” (Matt 8:9-13) and the Pharisees question Jesus’s non-observance of fasting traditions (Matt 8:14-17). One of the indications you are a true disciple of Jesus disciple of Jesus is that you are suffering in the same ways as Jesus.