Shouldn't while evaluate its conditions in order? e.g.
while( ( offers = visit_url( "makeoffer.php" ) ) && contains_text( offers , "Pending Trade Offers (Incoming)" ) )
Should do what is in the loop as long as you have pending incoming trades, shouldn't it?
If not, can someone smarter than...