CodeIgniter URI segments captured as variables?

Posted by Zen Savona on Stack Overflow See other posts from Stack Overflow or by Zen Savona
Published on 2011-01-15T07:50:36Z Indexed on 2011/01/15 7:53 UTC
Read the original article Hit count: 180

Filed under:
|

well, i have a function within a controller called test, and i can access it by going to http://localhost/nwk/control/test

this is my function. I want to use the data given in the next segment from the "test" as a php variable.

so if i put

function test() { $var $this->uri->segment(3); echo $var; }

according to the user guide if I enter control/test/data, my variable should be equal to 'data'?

doesn't seem to be working.

Am I missing something here?

© Stack Overflow or respective owner

Related posts about php

Related posts about codeigniter