YAFLogo

Posted by: metta123 - Tuesday, 2 October 2012 17:24:09
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.

Posted by: tha_watcha - Tuesday, 2 October 2012 17:36:28
[quote=metta123;56480]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.[/quote] Take a look at the existing Pages, you need to add the Items to the Page Links... [code=csharp;-1] protected void Page_Load([NotNull] object sender, [NotNull] EventArgs e) { if (this.IsPostBack) { return; } this.PageLinks.AddLink(this.Get().Name, YafBuildLink.GetLink(ForumPages.forum)); this.PageLinks.AddLink(this.GetText("ADMIN_ADMIN", "Administration"), string.Empty); this.Page.Header.Title = this.GetText("ADMIN_ADMIN", "Administration");[/code]

Posted by: metta123 - Tuesday, 2 October 2012 18:42:39
I did it, thank you for pointing me in the right direction. I enjoyed getting to the bottom of it.:)