Issue with dynamic horizontal dropdown menu
Hi All
Am new with sitefinity.Am using sitefinity4.4. In my project i want to use horizontal dropdown menu with custom selection of pages.Now am using Horizontal With DropDown Menu Navigation widjet.But here there is no options for custom selection of pages.
Any one plz give me a solution for show horizontal dropdown menus with custom selection of pages.
Regards,
Pretty
Dear Pretty
I might not understand your term 'custom selection of pages'. The Navigation Widget will include all pages that have the checkbox 'Show in Navigation' checked under the 'Titles & Properties' section of the page.
You can however make for example a GroupPage and have that page as an starting point for the navigatin widget.
If you are looking for a way to tell within the navigation widget which pages to include or not - then I am sorry that is not possible at the moment (and wont probably for the next 12 month)
Markus
Hi Markus
Thank you for your response. But my issue is not yet solved.In my project there is more than 200 pages.In this 20 pages set 'Show in Navigation' property as checked.Am using both vertical menu and horizontal menu in my project.So i want to show all these 20 pages in vertical navigation and only selected 10 pages with sub menu in horizontal navigation.How is this possible.
Hop now you got my actual problem.am waiting for your response
Regards,
Pretty
Dear Pretty
Sorry I don't think what you want an be achieved out of the box and would need some custom programming.
Markus
Dear Markus
Can you plz give a sample for creating custom navigation control
Regards
Pretty
Dear Pretty
I guess in order for anyone to help you you would need to specify your needs a bit more. Anyone helping would need to know how how and where to pick the pages you want to show.
Would it need to be dynamic or could it be hardcoded.
How would the control know which pages to show. So you would need to state your sites set up and what would happen when with wich pages.
Markus
Pretty,
I believe what you are wanting is to be able to use the horizontal menu with drop downs and be able to select the pages the menu will use. While this can be done out of the box, the drop downs will not happen as the selected pages option will only load in those pages in which you select. We had to tweak the NavigationControl to accommodate this functionality.
<
toolboxesConfig
xmlns:config
=
"urn:telerik:sitefinity:configuration"
xmlns:type
=
"urn:telerik:sitefinity:configuration:type"
>
<
toolboxes
>
<
toolbox
name
=
"PageControls"
>
<
sections
>
<
add
name
=
"NavigationControlsSection"
>
<
tools
>
<
add
type
=
"SitefinityWebApp.Widgets.Navigation.NavigationalControl, SitefinityWebApp"
name
=
"Navigation"
/>
</
tools
>
</
add
>
</
sections
>
</
toolbox
>
</
toolboxes
>
</
toolboxesConfig
>
Hi Richard,
Another way to deal with this is to specify a template in the 'Design Settings' of the standard navigation control.
'Template' bascially refers to 'User-Control' and you get to override the behaviour of the standard control, implementing whatever code you want, depending on your choices on the base control and the RadMenu events you provide in your user-control.
I used this approach to implement a menu that was a combination of some custom Mega-Dropdowns and standard multi-level dropdowns, and change details such as the tool-tip behaviour etc.
MB,
You are correct if all you want to do is just override the template. I am sure in the template you could add additional pages to the menu, but my post was talking about the limitation with using the SelectedPages option. The code for the NavigationControl will only send back the pages in which you select. It doesn't allow for returning the selected pages and the child pages of those selected pages.
@Richard
Yep, no argument - Sitefinity + RadMenu provides you multiple ways to skin the same cat.
In my case, I used the standard control to set the basic properties to horizontal mode and limited the selection to the 1st level items.
In my 'template' I managed the ItemDataBound event, where I added a custom mega-dropdown where appropriate, or built the standard drop-down set where it wasn't. The second part was done by running down the SiteMap from the ItemDataBound item, and adding its child menu items.
However, I could also have added using a separate data source, or chosen the custom navigation option if I wanted total selection control of the menu, and built whatever I wanted using the template control.
Richard,
I tried to download the zip file you link to and get a server error. Can you provide the link for me to download that control?
Thanks!
Sorry for the delay. I have re-uploaded the archive with the cs file that we use in our 5.4 sites.