Hi DM,
In the msg_area.grp_list.sub_list array, when should the scan_ptr and last_read values be updated for a sub-board? For instance, when simply reading messages (i.e., not doing a newscan), would both of those be updated or would only last_read be updated? And conversely, when reading messages during a newscan, would only the scan_ptr value be updated, or would both scan_ptr and last_read be updated?
Also, it looks like there's a typo in the Synchronet JS documentation at http://www.synchro.net/docs/jsobjs.html - Under the "msg_area.grp_list.sub_list array" section, the last row in the table has "lead_read" - I believe that should be "last_read"?
Any time the currently displayed message number is greater than the current scan_ptr, the scan_ptr should be updated. For every message displayed, the last_read should be updated. These apply regardless of the method of message reading/scanning.
If a new message is posted in a sub-board and that's the only message in the sub-board, it seems that scan_ptr and last_read would point to that message (is that correct?). If the currently logged-in user reads that message, then scan_ptr and last_read would remain unchanged since that's the only message in the sub-board. During a newscan, how can a JavaScript script determine whether the user has read that message (even if it wasn't written to the user - so the MSG_READ attribute wouldn't be set)?
Re: last_read and scan_ptr values
By: Digital Man to Nightfox on Thu Mar 26 2015 21:55:01
If a new message is posted in a sub-board and that's the only message in the sub-board, it seems that scan_ptr and last_read would point to that message (is that correct?).
If the currently logged-in user reads that message,
then scan_ptr and last_read would remain unchanged since that's the only message in the sub-board.
During a newscan, how can a JavaScript script
determine whether the user has read that message (even if it wasn't written to the user - so the MSG_READ attribute wouldn't be set)?
Re: last_read and scan_ptr values
By: Nightfox to Digital Man on Fri Mar 27 2015 22:49:47
If a new message is posted in a sub-board and that's the only message in the sub-board, it seems that scan_ptr and last_read would point to that message (is that correct?). If the currently logged-in user reads that message, then scan_ptr and last_read would remain unchanged since that's the only message in the sub-board. During a newscan, how can a JavaScript script determine whether the user has read that message (even if it wasn't written to the user - so the MSG_READ attribute wouldn't be set)?
I've done a little bit more testing this morning, and now I'm wondering if 0 is a meaningful value for scan_ptr? If I post a new message in an empty sub-board, it seems that the scan_ptr value for that sub-board is 0 until I read the message I posted.
A related question is, will a message number
(the 'number' property in a message header) ever be 0?
currentlyIf a new message is posted in a sub-board and that's the only message in the sub-board, it seems that scan_ptr and last_read would point to that message (is that correct?). If the
determinelogged-in user reads that message, then scan_ptr and last_read would remain unchanged since that's the only message in the sub-board. During a newscan, how can a JavaScript script
writtenwhether the user has read that message (even if it wasn't
wonderingto the user - so the MSG_READ attribute wouldn't be set)?
I've done a little bit more testing this morning, and now I'm
anif 0 is a meaningful value for scan_ptr? If I post a new message in
isempty sub-board, it seems that the scan_ptr value for that sub-board
(*.SID)0 until I read the message I posted.
Correct. Posting a message does not change any message pointers and the initial pointer value will be 0 (no message).
A related question is, will a message number
(the 'number' property in a message header) ever be 0?
No. 0 is a special value indicating "no message". You can read about SMB message numbers here: http://synchro.net/docs/smb.html#Index File
Yeah, that was fixed quite a while ago but the jsobjs.html hasn't be re-generated since then. Thanks,I don't remember exactly now why, but i know that i could not regenerate jsobs.html from source code. I had a wrong html output:
digital man
Sysop: | fluid |
---|---|
Location: | wickliffe, ohio |
Users: | 5 |
Nodes: | 10 (0 / 10) |
Uptime: | 202:31:19 |
Calls: | 50 |
Files: | 15,838 |
Messages: | 50,758 |