Moved random links code to showFragment() for better functionality.