rewrite applicaton.php and using layer_link