Given that the wolf would eat the goat, the goat would eat the cabbage but the wolf wouldn't eat the cabbage.
So, leave the wolf and cabbage behind (at side 1) and take the goat to the other side (side 2) of the river.
Then, come back with the empty boat from side 2 to side 1.
Take the wolf (or the cabbage) from side 1 to side 2 of the river.
Now, observe that, the goat is already on side 2, and the wolf and the goat can't be on the same side as the wolf would eat the goat, So, leave the wolf on side 2 and come back with the goat from side 2 to side 1.
Leave the goat on side 1 and take the cabbage from side 1 to side 2.
Now, come back with the empty boat from side 2 to side 1 and take the goat from side 1 to side 2.
In this way, the farmer can carry himself and his purchase to the other side of the river.