You need to sign in to do that
Don't have an account?
ramya raghava
apex:tab How to call a custom tab from li tag
I have a list of names with li tags and custom salesforce tabs with the same names. how can make a tab active when i select respected name from the list.
<apex:page>
<li><a href="#">My Tabs</a>
<ul>
<li><a href="#">My First</a></li>
<li><a href="#">My Second</a></li>
</ul>
</li>
<apex:tabPanel switchType="client" selectedTab="t1" id="tab_pannel">
<apex:tab label="My First" name="t1" id="tabOne">
...
</apex:tab>
<apex:tab label="My Second" name="t2" id="tabtwo">
...
</apex:tab>
</apex:tabPanel>
</apex:page>
(ex:Here when i select My First the tab My First should be active....)
<apex:page>
<li><a href="#">My Tabs</a>
<ul>
<li><a href="#">My First</a></li>
<li><a href="#">My Second</a></li>
</ul>
</li>
<apex:tabPanel switchType="client" selectedTab="t1" id="tab_pannel">
<apex:tab label="My First" name="t1" id="tabOne">
...
</apex:tab>
<apex:tab label="My Second" name="t2" id="tabtwo">
...
</apex:tab>
</apex:tabPanel>
</apex:page>
(ex:Here when i select My First the tab My First should be active....)
Try to do the following and see:
1. converting the anchor tags to <apex:comamndLink> and pass the name of the li tab as param.
2. Converting the selectedtab={!selectedTab}" - a controller variable and based on the param, change the selectedTab variable.
Hope it works.
Thanks