YAFLogo

kcril
  • kcril
  • 52.6% (Neutral)
  • YAF Forumling Topic Starter YAF Version: 2.3.0.2
2 years ago
i don't want yafheader menu to appear on login page, how can i remove top menu
Sponsor

tha_watcha
  • tha_watcha
  • 100% (Exalted)
  • YAF.NET Project Lead 🤴 YAF Version: 3.0.3
2 years ago
It should work if you modify the visibilitity in the Forum control.

In the Project YAF.Web Forum.cs change.,.

this.currentForumPage.ForumHeader.Visible = this.currentForumPage.ShowToolBar;

to..

this.currentForumPage.ForumHeader.Visible = this.currentForumPage.ShowToolBar && BoardContext.Current.ForumPageType is not ForumPages.Account_Login;
kcril
  • kcril
  • 52.6% (Neutral)
  • YAF Forumling Topic Starter YAF Version: 2.3.0.2
2 years ago
Thank you for your answer but I am getting these errors:
Error CS0117 'ForumPages' does not contain an 'Account_Login' definition
Error CS0103 Name 'BoardContext' does not exist in current context
Error CS8370 is not available in c# 7.3. please use language version 9.0

 Adsız.png You have insufficient rights to see the content.
tha_watcha
  • tha_watcha
  • 100% (Exalted)
  • YAF.NET Project Lead 🤴 YAF Version: 3.0.3
2 years ago
Then i guess it would be...

this.currentForumPage.ForumHeader.Visible = this.currentForumPage.ShowToolBar && YafContext.Current.ForumPageType != ForumPages.login;
kcril
  • kcril
  • 52.6% (Neutral)
  • YAF Forumling Topic Starter YAF Version: 2.3.0.2
2 years ago
thank you for helping
YAF Logo Copyright © YetAnotherForum.NET & Ingo Herbote. All rights reserved
About Us

The YAF.NET is an open source .NET forum project. YAF.NET is supported by an team of international developers who are build community by building community software.

Powered by Resharper Donate with PayPal button