Can you add tooltips to navigation

Posted by Community Admin on 05-Aug-2018 17:12

Can you add tooltips to navigation

All Replies

Posted by Community Admin on 26-Nov-2013 00:00
Can you add tooltips to the navigation in any way? It's to help with the site's SEO
Posted by Community Admin on 26-Nov-2013 00:00
Hey Andy,

If you edit your navigation widget you select a template, click on edit template.
On the edit template screen, find the <a runat="server"... tag and add a title='<%# Eval ("UrlName") %>' .

By default however it seems they've locked out the description or html title, so you can only 'tooltip' the menu-name (UrlName) property. 
Posted by Community Admin on 06-Jun-2014 00:00

I have a vertical nav widget with 4 to 5 links and would like to add a tooltip to each of the links.

How do I go about doing this?

<ul class="sfNavVertical sfNavList">
        <navigation:NavigationContainer  runat="server"  DataSourceID="dataSource">
               <Templates>
                <navigation:NavigationTemplate>
                         <Template>
                           <li>
                                <a runat="server" href='<%# Eval("Url") %>' target='<%# NavigationUtilities.GetLinkTarget(Container.DataItem) %>'><%# Eval("Title") %></a>          
                            </li>
                         </Template>
                       <SelectedTemplate>
                            <li>
                                <a runat="server" href='<%# Eval("Url") %>' class="sfSel" target='<%# NavigationUtilities.GetLinkTarget(Container.DataItem) %>'><%# Eval("Title") %></a>          
                            </li>
                        </SelectedTemplate>
                    </navigation:NavigationTemplate>
                </Templates>
        </navigation:NavigationContainer>
    </ul>

 

 

 

Posted by Community Admin on 06-Jun-2014 00:00
Hi Jochem,
Would you know how this works?
I have a vertical nav widget with 4 to 5 links and would like to add a tooltip to each of the links.
How do I go about doing this?
<ul class="sfNavVertical sfNavList">

        <navigation:NavigationContainer  runat="server"  DataSourceID="dataSource">

               <Templates>

                <navigation:NavigationTemplate>

                         <Template>

                           <li>

                                <a runat="server" href='<%#
Eval("Url") %>' target='<%#
NavigationUtilities.GetLinkTarget(Container.DataItem) %>'><%#
Eval("Title") %></a>          

                            </li>

                         </Template>

                       <SelectedTemplate>

                            <li>

                                <a runat="server" href='<%#
Eval("Url") %>' class="sfSel" target='<%#
NavigationUtilities.GetLinkTarget(Container.DataItem) %>'><%#
Eval("Title") %></a>          

                            </li>

                        </SelectedTemplate>

                    </navigation:NavigationTemplate>

                </Templates>

        </navigation:NavigationContainer>

    </ul>
 
 
Posted by Community Admin on 09-Jun-2014 00:00
Hello Haleh,

I have tested the proposed solution by Jochem and it works fine. Below is the code used:
<ul class="sfNavVertical sfNavList">
    <navigation:NavigationContainer  runat="server"  DataSourceID="dataSource">
           <Templates>
            <navigation:NavigationTemplate>
                     <Template>
                        <li>
                            <a runat="server" href='<%# NavigationUtilities.ResolveUrl(Container.DataItem) %>' target='<%# NavigationUtilities.GetLinkTarget(Container.DataItem) %>'  title='<%# Eval ("UrlName") %>'><%# Eval("Title") %></a>         
                        </li>
                     </Template>
                   <SelectedTemplate>
                        <li>
                            <a runat="server" href='<%# NavigationUtilities.ResolveUrl(Container.DataItem) %>' class="sfSel" target='<%# NavigationUtilities.GetLinkTarget(Container.DataItem) %>' title='<%# Eval ("UrlName") %>' ><%# Eval("Title") %></a>         
                        </li>
                    </SelectedTemplate>
                </navigation:NavigationTemplate>
            </Templates>
    </navigation:NavigationContainer>
</ul>

I hope this helps.

Regards,
Svetoslav Manchev
Telerik
 
Do you want to have your say in the Sitefinity development roadmap? Do you want to know when a feature you requested is added or when a bug fixed? Explore the Telerik Sitefinity CMS Ideas&Feedback Portal and vote to affect the priority of the items
 
This thread is closed