Welcome Guest, Not a member yet? Register   Sign In
Tabbed selection on home page - passing variable to index controller
#8

[eluser]OES[/eluser]
You would just pass a var in the url. ie,

<li class="&lt;?=($selected == 'tab_1') ? 'active' : ''?&gt;"><a href="site_url() .tab_1">TAB 1</a></li>

Then in the index method you could pick up the parameter ie,

function index($tab = '')
{
$data['selected'] = ($tab) ? $tab : 'tab_1;
}

Have fun

Lee


Messages In This Thread
Tabbed selection on home page - passing variable to index controller - by El Forum - 11-19-2010, 06:08 PM



Theme © iAndrew 2016 - Forum software by © MyBB