Subj : file_area.dir object
To : All
From : Tegularius
Date : Mon Jul 13 2009 06:50 am
Re: file_area.dir object
By: Digital Man to Tegularius on Sat Jul 11 2009 00:09:49
The little job is almost done. I've discovered that it is just a matter of
assigning the desired internal code to bbs.curdir_code, i.e.:
bbs.curdir_code=newcode
If newcode is valid, then the change is made; if not, it isn't. The case
(upper or lower) of newcode doesn't matter. However, the value
of bbs.curdir_code is reported all in lower-case.
This brings up my remaining little question. I would like my .js to
recognize whether the change of directory is successful by comparing
newcode to bbs.curdir_code after an attempt to change it. However,
if the cases of the two strings don't match, the comparison returns false.
How do I change the case of a string to upper or lower? The guide mentions
toLowerCase and toUpperCase as methods of strings, but I can't make them
work. Are they obsolete? Could someone give an example of the syntax?
Oh yes, one more question, about console.getstr. This takes a string
as an optional argument. What is the purpose of this argument? It
doesn't appear to be either the string variable to be assigned (which
is done via the returned value) or a prompt. Something needs to be
there if one wants to use the other arguments, but I can't determine
what it does.
---
� Synchronet � The Bauding House - baudhous.synchro.net