Welcome Guest, Not a member yet? Register   Sign In
Updating config/routes.php using mysql
#9

[eluser]CroNiX[/eluser]
It looks like you are forgetting to insert an opening php tag at the top of the routes.php file that you're writing, so it's being interpreted as text instead of a php file.
Before the loop, try changing
Code:
$data = '';
to
Code:
$data = "<?php \n";

Also it would be more readable if you inserted a line break at the end of each route.
Code:
$data =$data.'$route["' . $row->page_url . '"] = "' . $route . '";' . "\n";


Messages In This Thread
Updating config/routes.php using mysql - by El Forum - 07-14-2014, 04:44 AM
Updating config/routes.php using mysql - by El Forum - 07-14-2014, 09:03 AM
Updating config/routes.php using mysql - by El Forum - 07-14-2014, 09:55 AM
Updating config/routes.php using mysql - by El Forum - 07-14-2014, 12:14 PM
Updating config/routes.php using mysql - by El Forum - 07-14-2014, 12:27 PM
Updating config/routes.php using mysql - by El Forum - 07-14-2014, 12:51 PM
Updating config/routes.php using mysql - by El Forum - 07-14-2014, 12:53 PM
Updating config/routes.php using mysql - by El Forum - 08-20-2014, 01:51 PM
Updating config/routes.php using mysql - by El Forum - 08-20-2014, 03:12 PM
Updating config/routes.php using mysql - by El Forum - 08-21-2014, 01:46 AM
Updating config/routes.php using mysql - by El Forum - 08-21-2014, 07:34 AM
Updating config/routes.php using mysql - by El Forum - 08-21-2014, 08:33 AM



Theme © iAndrew 2016 - Forum software by © MyBB