• returning user node numbers

    From Ice@VERT to All on Thu Jun 9 18:23:40 2011
    is there a way to get a user's node number?

    example:

    1 - Sysop at main menu via telnet
    2 - test at main menu via telnet
    3 - john running ChatRoom via telnet
    4 - jane running ChatRoom via telnet

    john's info would be stored in the database under [node 3]

    so im trying to figure out how to get that number.

    var nodetext = "node" + user.nodenumber;



    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Digital Man@VERT to Ice on Fri Jun 10 16:12:32 2011
    Re: returning user node numbers
    By: Ice to All on Thu Jun 09 2011 06:23 pm

    is there a way to get a user's node number?

    example:

    1 - Sysop at main menu via telnet
    2 - test at main menu via telnet
    3 - john running ChatRoom via telnet
    4 - jane running ChatRoom via telnet

    john's info would be stored in the database under [node 3]

    so im trying to figure out how to get that number.

    var nodetext = "node" + user.nodenumber;

    Most users aren't on a node, so what this 'user' object in the above context? You can get the current node (of the user for which the current JS context is executing) with the bbs.node_num property. If you want to see if a current user is online, you can look thorugh the system.node_list array and see if the useron property matches the user number you're interested in (see exec/nodelist.js for an example).

    digital man

    Synchronet "Real Fact" #68:
    You can purchase the BBS Documentary DVD set at http://bbsdocumentary.com/order/

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