items.pl updated to function. added server.pl