The question arises: what is the proper blessing for searching out leaven on the evening before Passover?
What benediction does he pronounce?
R. Pappi said in Raba's name: ‘[. . . who hast commanded us] to remove leaven’ (l’vaer chametz).
R. Papa said in Raba's name: ‘[. . . who hast commanded us] concerning the removal of leaven’ (al biur chametz).
Now these are two different forms of the same word (spelled bet-ayin-resh) which means ‘to search’ or ‘to burn’ – very appropriate for this action. The difference is the first implies the past, the second the future. Several other examples are given in which there is a question of the grammatical form for a blessing, such as a circumcision, in with the person who pronounces the blessing is not (necessarily) the one performing the action. (The mohel acts on the father’s behalf).
But the future / past question is the important one. Because of the general principle articulated here:
Rab Judah said in Samuel's name: ‘For all precepts a benediction is recited prior [‘ober] to their being performed.’
Several biblical texts are then quoted to show that the Hebrew word ‘ober indicates priority. This is why for example we say the blessing and then drink the wine, we say the blessing and then eat the bread.
The major exception noted on the page is for the ritual bath (mikve). One immerses and only then says the blessing. The reason? The mikve is for purification – one goes into the water impure and emerges purified. That changed state is the proper one for saying a blessing.
A good way of thinking about it in any case - first say 'thank you' - place actions in a religious context - and then do them. Helps keep you in a holy (and appreciative) frame of mind.