Added functions of controlling tab contents