Topological phase transitions of random networks