Subj : Determining the posting message area
To   : Nightfox
From : Digital Man
Date : Tue May 07 2013 01:50 am

 Re: Determining the posting message area
 By: Digital Man to Nightfox on Mon Feb 18 2013 01:29 am

>   Re: Determining the posting message area
>   By: Nightfox to Digital Man on Sun Feb 17 2013 11:42 am
>
>  > Hi DM,
>  >
>  > In Synchronet's JavaScript, is there a (reliable) way to determine which
>  > message area the user is posting a message in?  From what I can tell,
>  > there are 2 JavaScript variables that store sub-board codes:
>  > bbs.smb_sub_code: The sub-board code of the message being read
>  > bbs.cursub_code: The sub-board code of the user's current sub-board
>  >
>  > The problem is that those two sub-board codes can be different, and the
>  > user could be posting a message in either of those sub-boards.  I'm not
>  > sure how to reliably tell which of those sub-boards the user is posting
>  > a message in.
>
> I can change the code to make one of those properties reflect the sub being
> posted on (probably smb_sub_*) or possibly introduce a new property, but
> that won't help you with existing sbbs installations.
>
> Of course, if the posting is initiated from a JS shell/module, then you
> know what sub is being posted to already, but I'm pretty sure you're asking
> in the context of an external editor (i.e. SlyEdit), in which case the
> answer is "currently, no".

I just committed a change to writemsg.cpp which I believe does what you want:
the bbs.smb_sub* properties will now reflect the sub-board being posted to,
always.

                                           digital man

Synchronet "Real Fact" #17:
Rob Swindell first learned to program in C by hacking on WWIV BBS software.
Norco, CA WX: 56.8�F, 74.0% humidity, 2 mph NNE wind, 0.04 inches rain/24hrs

---
� Synchronet � Vertrauen � Home of Synchronet � telnet://vert.synchro.net