Line voltage thermostat to shut off attic fan when outside temp is close to inside?
The only easy way (and non dynamic) is to have an external temp switch that turns on the internal main switch. Or the other way around depends how you want it to work.

Outside 35Degrees   Inside 25 Degrees
External >30(OFF) --> Internal >20(ON) --> FAN OFF

Outside 20 Degrees  Inside 25 Degrees
External &lt;30(ON) --> Internal >20(ON) --> FAN ON

My logic might be slighltly flawed but its the only way I can think of. Otherwise you have to buy some more inteligent system (usually expensive) or make your own microcontroller based relay

A Thermostat With Adjustable Hysteresis

http://electroschematics.com/6606/temperature-controlled-relay-circuit/

http://www.enercorp.com/contr/ettr.htm