Here is my code that is not working in wordpress theme. using this code trying to getting style.css file from wp root folder. what's problem in this code is any thing not correct like function name
<?php
function add_style() { wp_enqueue_style('style', get_stylesheet_uri()); }
add_action('wp_enqueue_scripts','add_style');
?>
But this code in wp function file is working correctly
register_nav_menus(array(
'primary' => __('Primary Menu')
)) ;
So can any one help me ?