CodeIgniter Forums
Stuck at the second hurdle - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20)
+--- Forum: Archived General Discussion (https://forum.codeigniter.com/forumdisplay.php?fid=21)
+--- Thread: Stuck at the second hurdle (/showthread.php?tid=57195)

Pages: 1 2


Stuck at the second hurdle - El Forum - 02-26-2013

[eluser]CodeIgNewbie[/eluser]
Not got there yet, but I'm wondering if you rerouted in "application/config/routes.php"

And if you did, does it need to be before, between or after the two existing elements?

It's really hazy when it tells you to "add code". Where? Inside a function, outside, which file sometimes!! Annoying.


Stuck at the second hurdle - El Forum - 02-26-2013

[eluser]CodeIgNewbie[/eluser]
I'm right there with you. The routing additions are typically ambiguous!! Don't really know where to go from here. Let's keep each other informed, OK?


Stuck at the second hurdle - El Forum - 02-26-2013

[eluser]soup7[/eluser]
here are my routes
$route['default_controller'] = "welcome";
$route['404_override'] = '';
$route['news/create'] = 'news/create';
$route['news/(:any)'] = 'news/view/$1';
$route['news'] = 'news';
$route['(:any)'] = 'pages/view/$1';
$route['default_controller'] = 'pages/view';

route just means when it sees what's in the first area, in the ['blah'] it routes to what comes next, pages/view etc...


if it's new/different route, just add it to the bottom will be fine i think

when they say 'add code', look how it changed from (where it was displayed) before, and you'll see where it changed.


Stuck at the second hurdle - El Forum - 02-26-2013

[eluser]CodeIgNewbie[/eluser]
Still 404!


Stuck at the second hurdle - El Forum - 02-26-2013

[eluser]soup7[/eluser]
at what point in the tutorial are you, where you're getting the 404?


Stuck at the second hurdle - El Forum - 02-26-2013

[eluser]CodeIgNewbie[/eluser]
Right at the end of the tute. The individual news articles.


Stuck at the second hurdle - El Forum - 02-26-2013

[eluser]soup7[/eluser]
can you view them 'all'? if so, you're having the same problem i am (as i cannot view just one either), just continue on- it will let you, get finished creating articles/etc and let me know...