If you're connecting the two computers directly ie not using a hub or switch, you'll need to use a 'crossover cable' and not the normal 'straight through cable'.
XP has a network setup wizard that is able to set up a machine to be the one through which others connect to the net. Quite handy but a pain in the @rse when you want to enter the settings directly.