get dynamic url slug in route file error |
i'm getting the dynamic url slugs in route file from database.
but i'm getting error here is the code require_once(BASEPATH.'database/DB'.EXT); $db =& DB(); $query = $db->get( 'your_table_name' ); $result = $query->result(); foreach($result as $row) { $route[ $row->slug ] = $row->controller_name; } Fatal error: require_once(): Failed opening required '/home/cmihub/public_html/real-estate/system/database/DBEXT' (include_path='.:/opt/alt/php56/usr/share/pear:/opt/alt/php56/usr/share/php') in /home/cmihub/public_html/real-estate/application/config/routes.php on line 56
EXT is no long a constant in the newer CI versions, use the ext name.
What did you Try? What did you Get? What did you Expect?
Joined CodeIgniter Community 2009. ( Skype: insitfx )
Just change this
PHP Code: require_once(BASEPATH.'database/DB'.EXT); to this PHP Code: require_once(BASEPATH.'database/DB.php'); |
Welcome Guest, Not a member yet? Register Sign In |