Subj : Dumb question 2
To   : John
From : Digital Man
Date : Tue Dec 01 2020 07:20 pm

 Re: Dumb question 2
 By: John to All on Tue Dec 01 2020 07:52 pm

> Hi Folks:
>
> I am starting to learn Jscript.

I know what you mean, but it's actually JavaScript (or ECMAScript). "JScript" is Microsoft's implementation of EMCAScript and not what Synchronet uses.

> Simple thing, how do I print something that
> has a CTRL A code or @LASTON@ ?

console.putmsg() will expand @-codes. Most other output methods will expand Ctrl-A codes. See http://wiki.synchro.net/custom:javascript#output for a reference.

> s ("tes"); print ("@LASTON@");

So that's the @-codes will expand to the *current* user's information. Instead, you wanted to print u.statistics.laston_date. And you probably want to convert that (number) to a human-readable string with something like system.datestr(), system.timestr(), or strftime(): http://synchro.net/docs/jsobjs.html
see exec/fingerservice.js or other exec/*.js files for examples.

or even convert it to a JavaScript Date object and use all its methods of stringification:
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date
--
                                           digital man

Synchronet/BBS Terminology Definition #58:
Phreak = Telephone system hack[er]
Norco, CA WX: 66.5�F, 23.0% humidity, 0 mph SW wind, 0.00 inches rain/24hrs

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