How to link to pages using a simple UL based navigation syst

Posted by Community Admin on 04-Aug-2018 19:12

How to link to pages using a simple UL based navigation system

All Replies

Posted by Community Admin on 30-May-2013 00:00

Hello,

I'm presently trying to figure out link to internal pages using a simple UL/LI structured navigation bar that I've already built and styled using CSS. I tried linking to the page name of each page, but that returns an error message that starts with:

Server Error in '/Default' Application.
Culture is not supported.
Parameter name: name

I'm assuming I do not have the correct path/name but don't know how that works in Sitefinity.
What is the href equivalent in Sitefinity for something that would normally be:
<a href="home.html">Home</a>

I also attempted to use the Navigation widget assuming that it would automatically know where to find the pages and that worked slightly better with no server-side error message but when I clicked a nav button it only displayed a blank page with "This Page is Not Accessible" in the middle of it.  That led me to wonder if navigation doesn't work in Preview mode. Is that true?  If so, how/where does one view the site to test navigation functionality?

Also, trying to style the Navigation widget buttons became way too convoluted when I tried to style the buttons to look exactly like the ones I already have. After re-assigning new CSS values to the Sitefinity CSS classes I found in Firebug that they were being overwritten by some telerik classes. So I think it would be much easier to just plug in my pre-existing nav structure and figure out what the correct path structure is to apply to each button's href value.

Thanks so much!
Cole

Posted by Community Admin on 03-Jun-2013 00:00

Also take a look at the community extension called CleanNav. It pretty much does what you are looking for (A clean UL based navigation structure). It is much easier to work with than the built in nav widgets.

Posted by Community Admin on 03-Jun-2013 00:00

Take a look at the community project "CleanNav". It pretty much does what you are looking for and is much easier to use than the built in navigation widgets.

Posted by Community Admin on 04-Jun-2013 00:00

Hello guys,

 Cole, as Michael suggested already, you can use the CleanNav, offered on the marketplace. Here's a link to it:
http://www.sitefinity.com/developer-network/marketplace/publishers/aptera-inc/cleannav-control

Also, once you decide which mode of the navigation you are going to use, you can create a skin for the navigation control or take advantage of the built-in skins that come from our RadControls. All RadControls are included in Sitefinity, as well as they build-in skins. Take a look at this article for some information about them. In case you want to use the build-in skins for the navigation, you simply need to enter the name of the chosen skin in the Navigation widget designer-> expand Design Settings -> Css Wrapper Class (skin) textbox. 
You can also create your own custom skins for the navigation widget. Note that they have to be included in a registered theme. Then, you simply enter the name of your skin in the edit panel of the navigation (same as with the embedded skins) to make the it work. The only thing you need to keep in mind is the way you declare the css properties in your stylesheet - they should be placed between the brackets of a rule, similar to this one:

 .[name of control, used for this navigation type] _ [name of your custom skin] styles

You can also take a look at this forum thread for further reference.

Regards,
Jen Peleva
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 Public Issue Tracking system and vote to affect the priority of the items

Posted by Community Admin on 04-Jun-2013 00:00

Thank you both for taking the time to respond to my post.

I reviewed the suggestions provided but feel that they are overkill and/or would quickly become too time-consuming to attempt to figure out how to use exactly how I need it. Surely there must be a simple(r) way to wire up some href links in my already-completed UL-based nav bar? This seems like this should be very easy to implement considering it's usually a very straight-forward process in HTML, but so far has proven to be the most challenging aspect I've come across in Sitefinity.

Perhaps my original post had too many questions that diverted away from the main point so I'll rephrase it:  How can I wire up a simple UL-based navigation in Sitefinity without using any Rad-based components or third-party plugins? Specifically what is the URL path-naming structure to link from one page to another?

Thanks again for your time!
Cole

Posted by Community Admin on 04-Jun-2013 00:00

The reason we are recommending these ways is because it will function with the sitemap structure automatically so you don't have to manually update the template all the time.

But you can certainly link to the pages manually with HTML as well. You are just going to have to keep the links up to date. You can get the links for a given page by going to Pages, and then hovering over the "View" link for each page to get the link location.

I would still recommend CleanNav, at least until Telerik gets the 6.1 update out which is supposed to introduce a new navigation widget that doesn't use the RadControls, but a UL based navigation structure without need for Javascript and all that stuff. Its a bit more work for upgrades as you have to upgrade the DLL with each release, but it is still better than having to manually maintain the template every time you add a page. Good luck!

Posted by Community Admin on 06-Jun-2013 00:00

Thank you Michael.
I tried hovering over the "view" link and found the url path displayed at the bottom of my browser. However if I click on that link to view the page, I get a blank page with a message in the center that says "This page is not accessible". Same thing if I view it by clicking on a Nav button in preview mode. Any ideas why this is happening?

Thanks again!
Cole

Posted by Community Admin on 06-Jun-2013 00:00

Then it sounds like you have something else going on here. You'll have to get one of the Telerik guys to help. I mean as long as it is actually published, and you haven't set any weird permissions for things, that shouldn't happen, which means you have a broken setup somewhere.

Posted by Community Admin on 06-Jun-2013 00:00

Ok, yeah, I kinda thought something might be "broken" when I saw that.  Thanks again for you time and help!

Posted by Community Admin on 11-Jun-2013 00:00

Hello guys,

Cole, it's possible that you have a Custom errors section enabled in your web.config. If this is the case, you won't see the real reason behind the error. I would advise you to set customErrors to off and see the real exception that is raised when you try to open a page. Here's how it should look (in your web.config):

<customErrors mode="Off"></customErrors>
 You can send the StackTrace here or open a support ticket where we'll examine the problem in details (in the ticket you'll be able to provide us with backend credentials to your website for further investigation).

Regards,
Jen Peleva
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 Public Issue Tracking system and vote to affect the priority of the items

This thread is closed