Advertisement:

Author Topic: Menu handling  (Read 17444 times)

Offline Illori

  • Project Manager
  • SMF Legend
  • *
  • Posts: 50,748
Menu handling
« on: September 19, 2011, 06:09:07 AM »
The development team is considering ways to better handle the menu in future versions. Some have suggested
  • storing the menu in the database where custom changes to the menu will not be overridden during upgrades
  • Also they are considering some type of menu editor built into SMF
What do you all think?
« Last Edit: September 19, 2011, 09:42:24 AM by Illori »

Offline Robert.

  • SMF Friend
  • SMF Hero
  • *
  • Posts: 4,074
  • Gender: Male
    • nedroden on GitHub
Re: Menu handling
« Reply #1 on: September 19, 2011, 10:48:41 AM »
I don't use menu editors a lot, but it would be a great feature though. Especially because 10% of the support requests are how to create a new tab
Software Engineering student
DraiWiki | Project Alpha

Offline Joker™

  • SMF Friend
  • SMF Hero
  • *
  • Posts: 5,914
  • Gender: Male
    • siddhartha-gupta on GitHub
Re: Menu handling
« Reply #2 on: September 20, 2011, 04:13:31 PM »
storing the menu in the database where custom changes to the menu will not be overridden during upgrades
But won't it be placing more pressure and queries on DB and specially when server is down, i.e when site is lagging and you are calling menu from database.

Also calling menu for everyone including guests from database doesn't sound good to me performance wise :P.


Also they are considering some type of menu editor built into SMF
That sounds like some cool feature to have.
Github Profile
Android apps
Medium

How to enable Post Moderation

"For the wise man looks into space and he knows there is no limited dimensions." - Laozi

All support seeking PM's get microwaved

Offline lurkalot

  • Sophist Member
  • *****
  • Posts: 1,270
  • Gender: Male
  • Tinyportal Support
    • guitaristguild on Facebook
    • Tinyportal on GitHub
    • @GuitaristGuild on Twitter
    • Guitarist Guild
Re: Menu handling
« Reply #3 on: September 20, 2011, 05:22:05 PM »
I love the idea of a menu manager as core feature.  To be honest I asked about this over a year ago, Add menu button function

Offline Antechinus

  • SMF Friend
  • SMF Super Hero
  • *
  • Posts: 24,246
  • Master of BBC Abuse
Re: Menu handling
« Reply #4 on: September 20, 2011, 05:27:17 PM »
The development team is considering ways to better handle the menu in future versions. Some have suggested
  • storing the menu in the database where custom changes to the menu will not be overridden during upgrades
  • Also they are considering some type of menu editor built into SMF
What do you all think?

We had this discussion in the team/beta boards already, and it was pointed out that calling the menu directly from the db would be very bad for large sites. For good scalability, any editor would have to write to a flat file.

Offline Joker™

  • SMF Friend
  • SMF Hero
  • *
  • Posts: 5,914
  • Gender: Male
    • siddhartha-gupta on GitHub
Re: Menu handling
« Reply #5 on: September 20, 2011, 05:44:52 PM »
We had this discussion in the team/beta boards already, and it was pointed out that calling the menu directly from the db would be very bad for large sites. For good scalability, any editor would have to write to a flat file.
Just a thought -- what if some mod has made the edit to the file already?
Github Profile
Android apps
Medium

How to enable Post Moderation

"For the wise man looks into space and he knows there is no limited dimensions." - Laozi

All support seeking PM's get microwaved

Offline Matthew K.

  • SMF Super Hero
  • *******
  • Posts: 12,430
  • Gender: Male
    • matthew.kerle on Facebook
    • @matthew_kerle on Twitter
Re: Menu handling
« Reply #6 on: September 20, 2011, 05:48:50 PM »
Every time the menu is modified from the provided admin interface, the file is wiped and re-populated from the database menu table. This is already in the feature-set of my Menu Editor, not the lite version, but the full version.
We had this discussion in the team/beta boards already, and it was pointed out that calling the menu directly from the db would be very bad for large sites. For good scalability, any editor would have to write to a flat file.
Just a thought -- what if some mod has made the edit to the file already?

Offline live627

  • On Hiatus
  • SMF Hero
  • *
  • Posts: 5,620
  • Gender: Male
    • live627 on Facebook
    • live627 on GitHub
    • live627 on LinkedIn
    • @live627 on Twitter
    • livemods
Re: Menu handling
« Reply #7 on: September 20, 2011, 06:53:16 PM »
Every time the menu is modified from the provided admin interface, the file is wiped and re-populated from the database menu table.
That's called the cache. :p
Try not to become a man of success, but rather try to become a man of value.
- Albert Einstein

Offline Matthew K.

  • SMF Super Hero
  • *******
  • Posts: 12,430
  • Gender: Male
    • matthew.kerle on Facebook
    • @matthew_kerle on Twitter
Re: Menu handling
« Reply #8 on: September 20, 2011, 07:00:22 PM »
Except it's not the same...
Every time the menu is modified from the provided admin interface, the file is wiped and re-populated from the database menu table.
That's called the cache. :p

Offline live627

  • On Hiatus
  • SMF Hero
  • *
  • Posts: 5,620
  • Gender: Male
    • live627 on Facebook
    • live627 on GitHub
    • live627 on LinkedIn
    • @live627 on Twitter
    • livemods
Re: Menu handling
« Reply #9 on: September 20, 2011, 07:33:47 PM »
Ok, now I'm curious... how does it differ?
Try not to become a man of success, but rather try to become a man of value.
- Albert Einstein

Offline Matthew K.

  • SMF Super Hero
  • *******
  • Posts: 12,430
  • Gender: Male
    • matthew.kerle on Facebook
    • @matthew_kerle on Twitter
Re: Menu handling
« Reply #10 on: September 20, 2011, 07:39:06 PM »
It doesn't really, except for the fact it's not in /cache. It's not "SMF's cache" if you will.

Offline live627

  • On Hiatus
  • SMF Hero
  • *
  • Posts: 5,620
  • Gender: Male
    • live627 on Facebook
    • live627 on GitHub
    • live627 on LinkedIn
    • @live627 on Twitter
    • livemods
Re: Menu handling
« Reply #11 on: September 20, 2011, 07:40:33 PM »
You mean it doesn't expire?
Try not to become a man of success, but rather try to become a man of value.
- Albert Einstein

Offline Matthew K.

  • SMF Super Hero
  • *******
  • Posts: 12,430
  • Gender: Male
    • matthew.kerle on Facebook
    • @matthew_kerle on Twitter
Re: Menu handling
« Reply #12 on: September 20, 2011, 07:54:19 PM »
It's a flat file...with a menu array that is only re-populated when the menu is modified.
You mean it doesn't expire?

Offline 青山 素子

  • Server Team
  • SMF Super Hero
  • *
  • Posts: 17,067
  • 戦場ヶ原、蕩れ!
    • srvrguy on GitHub
    • @motokochan on Twitter
    • Nekomusume Moe
Re: Menu handling
« Reply #13 on: September 30, 2011, 11:37:01 AM »
Couldn't you just set a different expiration time on individual cache files? If you're going to cache data, you might as well keep that all in one place. Some cache files would expire much sooner, others would be nearly static.
Motoko-chan
Director, Simple Machines

Note: Unless otherwise stated, my posts are not representative of any official position or opinion of Simple Machines.


Offline Xarcell

  • SMF Hero
  • ******
  • Posts: 1,684
  • Gender: Male
  • SMF-DP Supporter
Re: Menu handling
« Reply #14 on: October 05, 2011, 01:10:54 PM »
It's a flat file...with a menu array that is only re-populated when the menu is modified.
You mean it doesn't expire?

+1

Offline JohnWayne999

  • Semi-Newbie
  • *
  • Posts: 90
    • AutoAward
Re: Menu handling
« Reply #15 on: October 13, 2011, 05:28:40 PM »
1) Menu Editor sounds excellent. Be sure to have a feature that lets you choose whether a button when pressed will open up in current window or will open up a new window. That'll be very good. For example I have a Chatroom button and I'd like it to open into a new window, rather than steering the user away from current.

2) Have the menus, buttons settings all in one central file so people don't need to apply changes to every single theme. The problem now is if you install new themes, the new themes won't have all the changes you've made to date. Having a centralised menu/button registry makes things a lot neater and flexible.

Offline Antechinus

  • SMF Friend
  • SMF Super Hero
  • *
  • Posts: 24,246
  • Master of BBC Abuse
Re: Menu handling
« Reply #16 on: October 13, 2011, 05:31:23 PM »
You're obviously still using 1.1.x.  SMF 2.0.x has all menus called from the same file. :)

Offline Matthew K.

  • SMF Super Hero
  • *******
  • Posts: 12,430
  • Gender: Male
    • matthew.kerle on Facebook
    • @matthew_kerle on Twitter
Re: Menu handling
« Reply #17 on: October 13, 2011, 05:41:15 PM »
The target variable is already an option for SMF 2.0, as is the flat file in the logic end of things, so it's loaded the exact same way into each theme.

But yes, Menu Editor would allow you to select a target through the interface.
1) Menu Editor sounds excellent. Be sure to have a feature that lets you choose whether a button when pressed will open up in current window or will open up a new window. That'll be very good. For example I have a Chatroom button and I'd like it to open into a new window, rather than steering the user away from current.

2) Have the menus, buttons settings all in one central file so people don't need to apply changes to every single theme. The problem now is if you install new themes, the new themes won't have all the changes you've made to date. Having a centralised menu/button registry makes things a lot neater and flexible.

Offline Account Abandoned

  • Full Member
  • ***
  • Posts: 512
Re: Menu handling
« Reply #18 on: October 25, 2011, 01:37:56 PM »
Menu editing like being where I can add menus to the main navigation? If that is the case, I would LOVE a feature like that :) Make it internal too or I mean make it where I can add custom menus to the ACP as well!

kat

  • Guest
Re: Menu handling
« Reply #19 on: October 25, 2011, 01:42:04 PM »
How difficult would it be, to do this in the way that Bloc did it, with Helios?