a hub is a very "dumb" device; a switch has some intelligence.
Data packets from the sending PC are broadcast through all ports of a hub hoping to find the target on one of them.
A switch on the other hand only sends data out to its intended target, resulting in a much more efficient network.
Switches, unlike hubs, can simultaneously send and receive data packets, which is known as "full-duplex" communication.
There are two internationally ratified standards for the pinout of an ethernet patch cable, 586A and 586B. A cable that's A on one end and B on the other is a crossover, used for directly connecting two PCs without a hub/switch.
here are those pinouts and some additional information:
http://www.duxcw.com/digest/Howto/ne...ble/cable5.htm