refactor news.php