the Haftara for Parshas Pinchas is normally about Eliyahu, for well-known reasons.
Yet, when it falls after 17 Tammuz, we read from the first chapter of Yirmiyahu instead, to fit the sad theme of this time of year.
Yet there is also a very strong connection between the Parsha itself and the Haftara from Yirmiyahu.
The first chapter of Yirmiyahu deals with his sanctification as a Navi. In Parshas Pinchas, Yehoshua is sanctified as a Navi in place of Moshe Rabbenu.
It cannot be coincidental that Yehoshua is the one who took us into Eretz-Yisrael , and Yirmiyahu is the one who, in his prophecies of punishment, took us out into exile.
During this period of time, the message is stark: We cannot take Eretz-Yisrael for granted- our rights to it are completely determined on whether we keep our part of the deal.
At the same time as we meet Yehoshua, we also meet Yirmiyahu, and its is up to us to decide, whose message will be fulfilled in our day.