• bbs.menu vs bbs.menu_exists

    From Digital Man@VERT to nolageek on Wednesday, January 15, 2020 09:31:39
    Re: bbs.menu vs bbs.menu_exists
    By: nolageek to Digital Man on Tue Jan 14 2020 11:12 pm

    Re: bbs.menu vs bbs.menu_exists
    By: Digital Man to nolageek on Tue Jan 14 2020 03:00 pm

    At minimum, a .asc or .msg menu display file is required. bbs.menu() first looks for the *most* applicable file format, not all file formats.

    But it will find .ans - I guess I expected bbs.menu() and bbs.menu_exists() to work with the same formats so they could work together.

    They do. That's why menu_exists() is failing, because you're doing it wrong. You *have* to have one of the lowest-common-denominator menu files (*.msg or *.asc).

    I could convert I
    gues (but then I'd have to always convert back and forth to edit them.)

    That or use an editor that supports Ctrl-A format files (e.g. PabloDraw).

    Are
    .msg and .asc faster or are they "more native" to synchronet? Just curious.

    Not faster, but better.

    digital man

    Synchronet "Real Fact" #93:
    Synchronet v3.16c was released in August of 2015 (5 years after v3.15b).
    Norco, CA WX: 44.4F, 97.0% humidity, 0 mph WSW wind, 0.00 inches rain/24hrs

    ---
    Synchronet Vertrauen Home of Synchronet [vert/cvs/bbs].synchro.net
  • From nolageek@VERT/CAPSHRIL to Gamgee on Wednesday, January 15, 2020 12:06:45
    Re: Re: bbs.menu vs bbs.menu_exists
    By: Gamgee to nolageek on Wed Jan 15 2020 07:49 am

    http://wiki.synchro.net/custom:menu_files

    Well I know that. I was just wondering why bbs.menu_exists() didn't test for the same set of menu types that bbs.menu() can display. It was just unexpected to have it not find my .ans. I really don't want to keep multiple copies in different formats and convert menus back and forth every time I have a new one made or make a change (especially while I'm in the process of making a lot of changes.)

    Either way, I just wanted to ask since it seemed inconsistant at the time, but I'm sure there's a reason so I'm not looking to die on this hill. :) I'm using a slightly less hidious way of accomplishing what I was doing, but not as readable as if I could have used bbs.menu_exists(); It's still down to 3 lines of code as opposed to 6 or 7 like it was before so yay. :)

    |01-|03nolageek

    ---
    Synchronet Capitol Shrill BBS - Washington, DC - capitolshrill.com
  • From Digital Man@VERT to nolageek on Wednesday, January 15, 2020 13:21:47
    Re: Re: bbs.menu vs bbs.menu_exists
    By: nolageek to Gamgee on Wed Jan 15 2020 12:06 pm

    Re: Re: bbs.menu vs bbs.menu_exists
    By: Gamgee to nolageek on Wed Jan 15 2020 07:49 am

    http://wiki.synchro.net/custom:menu_files

    Well I know that. I was just wondering why bbs.menu_exists() didn't test for the same set of menu types that bbs.menu() can display. It was just unexpected to have it not find my .ans. I really don't want to keep multiple copies in different formats and convert menus back and forth every time I have a new one made or make a change (especially while I'm in the process of making a lot of changes.)

    Either way, I just wanted to ask since it seemed inconsistant at the time, but I'm sure there's a reason so I'm not looking to die on this hill. :) I'm using a slightly less hidious way of accomplishing what I was doing, but not as readable as if I could have used bbs.menu_exists(); It's still down to 3 lines of code as opposed to 6 or 7 like it was before so yay. :)

    You really should use bbs.menu_exists() as it's doing the right thing. If you have a non-ANSI user and call bbs.menu() for a menu file that has no .msg or .asc equivalent, that user is just going to see an error message (no menu). Not a very good user experience.

    digital man

    Synchronet "Real Fact" #83:
    Donations to the Synchronet project are welcome @ http://wiki.synchro.net/donate
    Norco, CA WX: 64.9F, 52.0% humidity, 0 mph W wind, 0.00 inches rain/24hrs

    ---
    Synchronet Vertrauen Home of Synchronet [vert/cvs/bbs].synchro.net