(When it is said unto them) when the Prophet (pbuh) said to the people of Mecca: (Beware of that which is before you) of the matter of the Hereafter; you should believe in and strive for it (and that which is behind you) of the matter of this worldly life, such that you do not become deluded by it and by its splendour, (that haply ye may find mercy) in the Hereafter and do not get tormented.