Codeigniter get current route name in view file using single line Today we will learn how to get current route name in codeigniter view files or in view php files. We can do this by using single line code $this->uri->segment(1); this code will give you current route name from url. Example URL mywebsite.com/users/robert So for above example this code will give you " users " as output so by using this method you can simply get the current route name. Thank you.
PHP,WORDPRESS,CAKEPHP,JQUERY,PHP TUTORIALS,CAKEPHP TUTORIALS,JQUERY CODES, CSS CODES, HTML CODES,EXPO, React, React Native, Angular,OOPS ,PHP INTERVIEW QUESTIONS @shubham715