YAFLogo

metta123
  • metta123
  • 50.2% (Neutral)
  • YAF Camper Topic Starter
12 years ago
I've managed to create a couple of custom pages in forum that are bundled into the yaf.net source. I'm going to have to recompile the project.

My custom pages are missing the breadcrumb and I would like to include it. Could anyone advise me on where to locate the code for the breadcrumb and how to incorporate into my custom pages. I don't seem to be able to locate any documentation on this.

Is it something to do with PageLinks?? If so shouldn't it just detect my page. Do I need to add the page somewhere like I did in ForumPages.cs enum to get my custom pages detected.

Thank you.

Sponsor
tha_watcha
  • tha_watcha
  • 100% (Exalted)
  • YAF.NET Project Lead 🤴 YAF Version: 4.0.0 rc 2
12 years ago

I've managed to create a couple of custom pages in forum that are bundled into the yaf.net source. I'm going to have to recompile the project.

My custom pages are missing the breadcrumb and I would like to include it. Could anyone advise me on where to locate the code for the breadcrumb and how to incorporate into my custom pages. I don't seem to be able to locate any documentation on this.

Is it something to do with PageLinks?? If so shouldn't it just detect my page. Do I need to add the page somewhere like I did in ForumPages.cs enum to get my custom pages detected.

Thank you.

Originally Posted by: metta123 

Take a look at the existing Pages, you need to add the Items to the Page Links...


protected void Page_Load([NotNull] object sender, [NotNull] EventArgs e)
        {
            if (this.IsPostBack)
            {
                return;
            }

            this.PageLinks.AddLink(this.Get<YafBoardSettings>().Name, YafBuildLink.GetLink(ForumPages.forum));
            this.PageLinks.AddLink(this.GetText("ADMIN_ADMIN", "Administration"), string.Empty);

            this.Page.Header.Title = this.GetText("ADMIN_ADMIN", "Administration");
metta123
  • metta123
  • 50.2% (Neutral)
  • YAF Camper Topic Starter
12 years ago
I did it, thank you for pointing me in the right direction. I enjoyed getting to the bottom of it.:)