![]() |
need help....first application - 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: need help....first application (/showthread.php?tid=34092) |
need help....first application - El Forum - 09-18-2010 [eluser]Unknown[/eluser] Hi Guys, I am very new to CI...Just started yesterday...I downloaded and setup CI and its working fine but now facing a problem I have the following controller... class Hello extends Controller { function Hello() { parent::Controller(); } function index() { $this->load->view('hello_world'); } function world() { echo "<h1>Hello World</h1>"; } } and I have the default controller in routes.php setup as hello. when I go to the following link...http://codeigniterapp/ all is fine and it shows me the hello_world.php view via the index function... but when I call this http://codeigniterapp/hello/world/ it doesnt show me any output via the world function. Dont know why it suppose to do that...shouldn't it ??? Looking forwad to your quick replies... Ahtasham need help....first application - El Forum - 09-18-2010 [eluser]Vega[/eluser] It sounds like it could be a problem with your config.php or your .htaccess files. If you want to use clean URLs you need to set the $config['index_page'] variable in config.php to blank string "". You will also need to put a .htaccess file in the root of your ci installation (search the forum for what to put in this). need help....first application - El Forum - 09-18-2010 [eluser]Unknown[/eluser] Thanks alot...got it now... |