[REBOL] Split-path correction Re:(2)

2000-02-28 Thread lmecir

Hi, Andrew,

 split-path %file.r
== [%./ "file.r"]

I don't think, that this is correct, because the second element of
the result has got a wrong type and, moreover, the first element
is incorrect, because the identity:

file = (append copy first r: split-path file second r)

is not preserved, which causes some problems when you want to
handle the following two cases:

a) %file.r
b) %./file.r

differently.

compare this to my version:

split-path %file.r
== [% %file.r]

split-path %./file.r
== [%./ %file.r]


 split-path %dir/
== [%./ "dir"]

this is totally incorrect, compare this to my version:

split-path %dir/
== [%dir/ %]

Regards,
Ladislav

 [EMAIL PROTECTED] wrote:
  after having some problems with split-path, here is my
version:
 
  (Andrew, it may be nice to have it in your %patch.r)

  split-path %file.r
  split-path %dir/

 These ones, I feel, aren't a problem. The existing
implementation of
 split-path is correct, I believe.

  split-path to file! ""

 I agree that this one's incorrect, and needs fixing.

 Andrew Martin
 Bored with getmsg...
 ICQ: 26227169
 http://members.xoom.com/AndrewMartin/
 --

 - Original Message -
 From: [EMAIL PROTECTED]
 To: [EMAIL PROTECTED]
 Sent: Saturday, 26 February 2000 9:23 PM
 Subject: [REBOL] Split-path correction


  Hi,
 
  after having some problems with split-path, here is my
version:
 
  (Andrew, it may be nice to have it in your %patch.r)
 
  split-path: func [
  {
  Splits a file or URL. Returns a block containing path
and
  target.
 
  Overcomes some limitations of the Core split-path like
  strange results for:
 
  split-path %file.r
  split-path %dir/
  split-path to file! ""
 
  Moreover, the identity:
 
  file = (append copy first r: split-path file
second r)
 
  is always preserved.
  }
  file [file! url!]
  /local path target
  ] [
  target: path: to string! file
  parse path [any [#"/" target: | skip]]
  path: copy/part path target
  reduce [to file path to file target]
  ]
 






[REBOL] exists? Re:(2)

2000-02-28 Thread lmecir


Hi,

try this:

exists? http://www.rebol.com/nonsense.r

Regards,
Ladislav


- Puvodní zpráva -
Od: [EMAIL PROTECTED]
Komu: [EMAIL PROTECTED]
Odesláno: 27. února 2000 1:52
Predmet: [REBOL] exists? Re:


 Hi, Ladislav.
  I know, that it has been discussed, but I think, that the
following
 improvement to Core Exists? may be useful.
  Any suggestions are welcome.

 Can you give an example where REBOL's 'exists? fails, and your's
works
 better, please?

 Andrew Martin
 ICQ: 26227169
 http://members.xoom.com/AndrewMartin/
 --



 - Original Message -
 From: [EMAIL PROTECTED]
 To: [EMAIL PROTECTED]
 Sent: Sunday, 27 February 2000 8:49 AM
 Subject: [REBOL] exists?


  Hi, Rebols,
 
  I know, that it has been discussed, but I think, that the
  following improvement to Core Exists? may be useful.
  Any suggestions are welcome.
 
  Regards,
  Ladislav
 
  exists?: func [
  {
  Determines if a file or URL exists.
 
  Checks for invalid HTML pages.
  }
  target [file! url!]
  /local port comp ts
  ][
  if error? try [
  port: make port! target
  query port
  ] [return false]
  if not port/status [return false]
  if port/scheme = 'HTTP [
  ts: to string! target
  if (to string! port/url) = ts [
  return true
  ]
  comp: copy "http://"
  if port/host [append comp port/host]
  if comp = ts [
  return true
  ]
  if (append copy comp #"/") = ts [
  return true
  ]
  if port/path [append comp port/path]
  if comp = ts [
  return true
  ]
  if port/target [append comp port/target]
  if comp = ts [
  return true
  ]
  return false
  ]
  true
  ]
 
 







[REBOL] none Re:

2000-02-28 Thread lmecir

Hi,

Your observation was reported to feedback by me before and it has
been assigned ticket #2409.

OTOH, if you check the code more thoroughly, URL! never changes to
File!.

Regards,
Ladislav


 Hi folks,

 I was just playing around with Ladislav's fix of SPLIT-PATH. I
was
 wondering why he converted the argument values to strings, since
this
 has the disadvantage that if the argument is a URL the result
will
 eventually get changed to a file.

 Then I noticed something really weird:

  path: file: %dir/file.ext
 == %dir/file.ext
  parse path [any [#"/" file: | skip]]
 == true
  file
 == "file.ext"
  insert path "parent/"
 == %dir/file.ext
  path
 == %parent/dir/file.ext
  head file
 == "parent/dir/file.ext"

 Even though we're parsing a file! , any pointer set within the
parse
 rule becomes a string! , and yet it's still pointing to the same
 underlying data. It can't, however, be used as an index with
COPY/PARSE:

  parse path [any [#"/" file: | skip]]
 == true
  copy/part path file
 ** Script Error: Invalid /part count: file.ext.
 ** Where: copy/part path file

 I never realized that you could view the same data with two
different
 datatypes. Is this intended? I think it would be much better to
have
 get-words in parse rules use the type of the data being parsed.


 BTW, I agree with Andrew that this behavior of SPLIT-PATH is
better
 than Ladislav's fix (unless READ is also fixed to read the
current
 directory for %""):

  split-path %file.ext
 == [%./ "file.ext"]
  read first split-path %file.ext
 == [%USER.R %TALK.R %rebol.r %REBOL.exe ...

  sp %file.ext; Ladislav's version
 == [% %file.ext]
  read first sp %file.ext
 ** Access Error: Cannot open /C/prog/rebol/.
 ** Where: read first sp %file.ext

 See you,
 Eric






[REBOL] Testing REBOL/View Beta List Re:(3)

2000-02-28 Thread carl

This problem sounds very odd.  We do not forward ALLY to LIST.  Either it
is a bug in our email handling, or it is a bug in your client filters.

I have not seen this problem here.  The original message did not appear on my copy of 
the main REBOL list. I did not see any sign of the problem until you posted your reply 
to the list.  I see no such duplication of messages (however, I do a lot of message 
filtering, so it is possible that the duplicates were filtered out on my side).

Does anyone else see this problem?

-Carl

PS: We have been experiencing a few other problems with our lists in recent weeks, so 
I'll be "postmaster" again for a few days to iron out some of the glitches and add a 
few needed features.  I'll also be moving the lists off our in-house server to another 
REBOL site that has higher speed service.

At 2/26/00 06:36 PM +0100, you wrote:


[EMAIL PROTECTED] wrote:

 Hello [EMAIL PROTECTED]!

 On 25-Feb-00, you wrote:

  i This message is addressed to the REBOL/View Beta list. Will it
  i end up on the main REBOL list? If so, View Beta Selma is
  i forwarding its messages to the wrong list.

 It came with the following (stripped for brevity) header:

 Return-Path: [EMAIL PROTECTED]
 Received: from brando.rebol.net (rebol.net [199.4.95.216]) by smv04.iname.net 
(8.9.3/8.9.1SMV2) with ESMTP id RAA24248 for [EMAIL PROTECTED] sent by 
[EMAIL PROTECTED]; Fri, 25 Feb 2000 17:05:37 -0500 (EST)
 Received: from office.rebol.net (IDENT:[EMAIL PROTECTED] [192.168.1.9]) by 
brando.rebol.net (8.9.3/8.9.3) with SMTP id PAA02547; Fri, 25 Feb 2000 15:07:26 -0800
 To: [EMAIL PROTECTED]
 From: [EMAIL PROTECTED]
 Reply-To: [EMAIL PROTECTED]
 Date: Fri, 25 Feb 2000 13:59:12 -0800
 Subject: [ALLY] Testing REBOL/View Beta List
 X-SELMA: [ALLY] 6764


Hmm, ALERT! Conspiracy theory. MS overtaken REBOL Technologies. Hey, folks, anyone 
willing to join me to visit Ukiah?

:-)

-pekr-


 Regards,
 Gabriele.
 --
 o) .-^-. (--o
 | Gabriele Santilli / /_/_\_\ \ Amiga Group Italia --- L'Aquila |
 | GIESSE on IRC \ \-\_/-/ /  http://www.amyresource.it/AGI/ |
 o) `-v-' (--o
 



[REBOL] Split-path correction Re:(2)

2000-02-28 Thread lmecir

Hi,

it isn't that bad. Have a look, please:

 split-path2 http://fgdfgdfg.Fgdfg/fgdfgdfg/dfgdfg
== [http://fgdfgdfg.Fgdfg/fgdfgdfg/ dfgdfg]
 type? second split-path2 http://fgdfgdfg.Fgdfg/fgdfgdfg/dfgdfg
== url!

Regards,
Ladislav

- Puvodní zpráva -
Od: [EMAIL PROTECTED]
Komu: [EMAIL PROTECTED]
Odesláno: 27. února 2000 19:26
Predmet: [REBOL] Split-path correction Re:



 From: [EMAIL PROTECTED]
  Hi,
 
  after having some problems with split-path, here is my
version:
 
  (Andrew, it may be nice to have it in your %patch.r)

 Not yet, Andrew !

 
  split-path: func [
  {
  Splits a file or URL. Returns a block containing path
and
  target.
 

 Not always. It has other bugs than the original.
 It breaks the splitting of URLs (I called your version
split-path2) :
  split-path http://fgdfgdfg.Fgdfg/fgdfgdfg/dfgdfg
 == [http://fgdfgdfg.Fgdfg/fgdfgdfg/ %dfgdfg]
  split-path2 http://fgdfgdfg.Fgdfg/fgdfgdfg/dfgdfg
 == [http://fgdfgdfg.Fgdfg/fgdfgdfg/ dfgdfg]


  Overcomes some limitations of the Core split-path like
  strange results for:
 
  split-path %file.r
  split-path %dir/
  split-path to file! ""

 The last expression can also be written like that :
 split-path %""

 
  Moreover, the identity:
 
  file = (append copy first r: split-path file
second r)
 
  is always preserved.

 Remember that you can have a look to the source of the original
split-path
 to improve it :
 source split-path

 Olivier.










[REBOL] Re: [ALLY] Initial Cursor Placement

2000-02-28 Thread carl

Mike,

will be in Beta 2, along with the ability to TAB and ENTER between fields.

-Carl


At 2/25/00 10:32 AM -0900, you wrote:
Hello,

Is it possible to control programmatically where the cursor goes when a
pane is displayed, for example in the first field or area, so the user can
immediately begin entering data, instead of having to mouse click first???

Thanks.

Mike.
 



[REBOL] Testing REBOL/View Beta List Re:(4)

2000-02-28 Thread Petr . Krenzelok



[EMAIL PROTECTED] wrote:

 This problem sounds very odd.  We do not forward ALLY to LIST.  Either it
 is a bug in our email handling, or it is a bug in your client filters.

 I have not seen this problem here.  The original message did not appear on my copy 
of the main REBOL list. I did not see any sign of the problem until you posted your 
reply to the list.  I see no such duplication of messages (however, I do a lot of 
message filtering, so it is possible that the duplicates were filtered out on my 
side).

 Does anyone else see this problem?

 -Carl


Carl,

I have the same problem here. Here is cut off of your previous Ally post:

Received:  from atlanta.trz.cz (atlanta.sec.trz.cz [194.196.82.132]) by orion.trz.cz 
with SMTP
 (Microsoft Exchange Internet Mail Service Version 5.5.2448.0) id 
YZT3XRPV; Mon, 28
 Feb 2000 02:13:09 -
Received:  from brando.rebol.net (rebol.net [199.4.95.216]) by atlanta.trz.cz 
(8.9.1/8.9.1) with
 ESMTP id CAA00167 for [EMAIL PROTECTED]; Mon, 28 Feb 2000 
02:10:06 +0100
Received: from office.rebol.net (IDENT:[EMAIL PROTECTED] [192.168.1.9]) by 
brando.rebol.net
 (8.9.3/8.9.3) with SMTP id SAA19211; Sun, 27 Feb 2000 18:12:24 -0800
To: [EMAIL PROTECTED]
From: [EMAIL PROTECTED]
Reply-To: [EMAIL PROTECTED]
Date: Sun, 27 Feb 2000 17:11:14 -0800
Subject: [ALLY] REB Site Updated
Message-ID: [EMAIL PROTECTED]
X-REBOL: 2.2.0.4.2 "The Internet Messaging Language (TM) WWW.REBOL.COM"
MIME-Version: 1.0
Content-Type: text/plain; charset="us-ascii"
Precedence: bulk
X-Sender: [EMAIL PROTECTED]
X-Mailer: QUALCOMM Windows Eudora Pro Version 4.0
X-SELMA: [ALLY] 6798
X-Mozilla-Status: 8001
X-Mozilla-Status2: 
X-UIDL: AAwwZIDAAAQne90rgAQkuGh0clz24pdb


-pekr-



[REBOL] Testing REBOL/View Beta List Re:(4)

2000-02-28 Thread pa . russo

This problem sounds very odd.  We do not forward ALLY to LIST.  Either it
is a bug in our email handling, or it is a bug in your client filters.

I have not seen this problem here.  The original message did not 
appear on my copy of the main REBOL list. I did not see any sign of 
the problem until you posted your reply to the list.  I see no such 
duplication of messages (however, I do a lot of message filtering, 
so it is possible that the duplicates were filtered out on my side).

Does anyone else see this problem?

-Carl

PS: We have been experiencing a few other problems with our lists in 
recent weeks, so I'll be "postmaster" again for a few days to iron 
out some of the glitches and add a few needed features.  I'll also 
be moving the lists off our in-house server to another REBOL site 
that has higher speed service.

At 2/26/00 06:36 PM +0100, you wrote:


[EMAIL PROTECTED] wrote:

  Hello [EMAIL PROTECTED]!

  On 25-Feb-00, you wrote:

   i This message is addressed to the REBOL/View Beta list. Will it
   i end up on the main REBOL list? If so, View Beta Selma is
   i forwarding its messages to the wrong list.

  It came with the following (stripped for brevity) header:

  Return-Path: [EMAIL PROTECTED]
  Received: from brando.rebol.net (rebol.net [199.4.95.216]) by 
smv04.iname.net (8.9.3/8.9.1SMV2) with ESMTP id RAA24248 for 
[EMAIL PROTECTED] sent by [EMAIL PROTECTED]; Fri, 25 Feb 2000 
17:05:37 -0500 (EST)
  Received: from office.rebol.net (IDENT:[EMAIL PROTECTED] 
[192.168.1.9]) by brando.rebol.net (8.9.3/8.9.3) with SMTP id 
PAA02547; Fri, 25 Feb 2000 15:07:26 -0800
  To: [EMAIL PROTECTED]
  From: [EMAIL PROTECTED]
  Reply-To: [EMAIL PROTECTED]
  Date: Fri, 25 Feb 2000 13:59:12 -0800
  Subject: [ALLY] Testing REBOL/View Beta List
  X-SELMA: [ALLY] 6764


Hmm, ALERT! Conspiracy theory. MS overtaken REBOL Technologies. 
Hey, folks, anyone willing to join me to visit Ukiah?

:-)

-pekr-


  Regards,
  Gabriele.
  --
  o) .-^-. (--o
  | Gabriele Santilli / /_/_\_\ \ Amiga Group Italia --- L'Aquila |
  | GIESSE on IRC \ \-\_/-/ /  http://www.amyresource.it/AGI/ |
  o) `-v-' (--o


-- 
Paolo Russo
[EMAIL PROTECTED]
_
PERD s.r.l.
Virtual Technologies for Real Solutions
http://www.perd.com



[REBOL] Testing REBOL/View Beta List Re:(4)

2000-02-28 Thread chris

[EMAIL PROTECTED] wrote:
 
 This problem sounds very odd.  We do not forward ALLY to LIST.  Either
 it is a bug in our email handling, or it is a bug in your client
 filters.
 
 I have not seen this problem here.  The original message did not
 appear on my copy of the main REBOL list. I did not see any sign of
 the problem until you posted your reply to the list.  I see no such
 duplication of messages (however, I do a lot of message filtering, so
 it is possible that the duplicates were filtered out on my side).

I have filters set up in Netscape as follows:

ALLY: the 'to' of this message 'is' '[EMAIL PROTECTED]'
REBOL: the 'to' of this message 'is' '[EMAIL PROTECTED]'

Currently (in the last week) all the mails, including those with [ALLY]
at the beginning of the header go to the REBOL folder.  No duplicates
though.

- Chris



[REBOL] Split-path correction Re:(3)

2000-02-28 Thread giesse

[EMAIL PROTECTED] wrote:

 clean-path is as buggy (even more) :
  clean-path http://www/dfhfgh/../fghfgh
 == http://www/dfhfgh/../fghfgh
 (doesn't remove . and .. in URLs)

This is intended behaviour, as stated on this ml some time ago.
".."s may be relevant in URLs (in particular for FTP).

Ciao,
/Gabriele./
o) .-^-. (--o
| Gabriele Santilli / /_/_\_\ \ Amiga Group Italia --- L'Aquila |
| GIESSE on IRC \ \-\_/-/ /  http://www.amyresource.it/AGI/ |
o) `-v-' (--o



[REBOL] remove

2000-02-28 Thread jmaselli







Joe Maselli
KHS Student Activities
79 Westfield Ave.  Danielson, CT 06239
voice: (860) 779-6646  --  fax: (860) 774-0846
http://activities.killingly.k12.ct.us
[[ JVM.VCF : 3373 in winmail.dat ]]

 winmail.dat


[REBOL] Disk free

2000-02-28 Thread guity

Hello, I'm creating a lot of new scripts with Rebol. I discovered it last week and I 
think it's fantastic.

I want know the amount of my hard disk and what is the free space in it ???

Thanks everyone

David Guitian
Ayuntamiento de La Coruña
Spain



[REBOL] Folders on Mac Re:(4)

2000-02-28 Thread versation

 I know this has nothing to do with the matter but just yesterday I
 downloaded the PPC version of REBOL and I don´t know why after I decompress
 it I can´t run REBOL without crashing my G3

 i had the same problem so i fell back to using REBOL 2.1.2.2.1.

 if you figure out what the problem is with the latest version, pls let me
 knowŠ

I had a problem, but I resolved it by trashing %REBOL Preferences in the
System Folder.

I am using the current version on a Pcc PPC 604.

Pat
--
Pat Ward - Versation Corp. - phone 847.506.9095
digital audio and digital media services
425 N. Douglas Avenue   | [EMAIL PROTECTED]
Arlington Heights IL 60004-6122 | http://versation.net/



[REBOL] Folders on Mac Re:(5)

2000-02-28 Thread djg

 I had a problem, but I resolved it by trashing %REBOL Preferences in the
 System Folder.

thx, this solved the problem.

-dg


 From: [EMAIL PROTECTED]
 Reply-To: [EMAIL PROTECTED]
 Date: Mon, 28 Feb 2000 10:39:46 -0600
 To: [EMAIL PROTECTED]
 Subject: [REBOL] Folders on Mac Re:(4)
 
 I know this has nothing to do with the matter but just yesterday I
 downloaded the PPC version of REBOL and I don´t know why after I decompress
 it I can´t run REBOL without crashing my G3
 
 i had the same problem so i fell back to using REBOL 2.1.2.2.1.
 
 if you figure out what the problem is with the latest version, pls let me
 knowŠ
 
 I had a problem, but I resolved it by trashing %REBOL Preferences in the
 System Folder.
 
 I am using the current version on a Pcc PPC 604.
 
 Pat
 --
 Pat Ward - Versation Corp. - phone 847.506.9095
 digital audio and digital media services
 425 N. Douglas Avenue   | [EMAIL PROTECTED]
 Arlington Heights IL 60004-6122 | http://versation.net/
 
 




[REBOL] Testing REBOL/View Beta List Re:(4)

2000-02-28 Thread larry

Hi Carl

Here is the header I got with your post "REB Site Updated":

From [EMAIL PROTECTED] Sun Feb 27 17:03:32 2000
Received: by mail.ecotope.com from localhost
(router,SLMail V2.7); Sun, 27 Feb 2000 17:03:32 -0800
Received: by mail.ecotope.com from brando.rebol.net
(199.4.95.216::mail daemon; unverified,SLMail V2.7); Sun, 27 Feb 2000
17:03:31 -0800
Received: from office.rebol.net (IDENT:[EMAIL PROTECTED] [192.168.1.9])
 by brando.rebol.net (8.9.3/8.9.3) with SMTP id SAA19286;
 Sun, 27 Feb 2000 18:13:28 -0800
To: [EMAIL PROTECTED]
From: [EMAIL PROTECTED]
Reply-To: [EMAIL PROTECTED]
Date: Sun, 27 Feb 2000 17:11:14 -0800
Subject: [ALLY] REB Site Updated
Message-Id: [EMAIL PROTECTED]
X-REBOL: 2.2.0.4.2 "The Internet Messaging Language (TM) WWW.REBOL.COM"
MIME-Version: 1.0
Content-Type: text/plain; charset="us-ascii"
Precedence: bulk
X-Sender: [EMAIL PROTECTED]
X-Mailer: QUALCOMM Windows Eudora Pro Version 4.0
X-SELMA: [ALLY] 6798

Hope this helps

Cheers

Larry

- Original Message -
From: [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Monday, February 28, 2000 1:48 AM
Subject: [REBOL] Testing REBOL/View Beta List Re:(3)


 This problem sounds very odd.  We do not forward ALLY to LIST.  Either it
 is a bug in our email handling, or it is a bug in your client filters.

 I have not seen this problem here.  The original message did not appear on
my copy of the main REBOL list. I did not see any sign of the problem until
you posted your reply to the list.  I see no such duplication of messages
(however, I do a lot of message filtering, so it is possible that the
duplicates were filtered out on my side).

 Does anyone else see this problem?

 -Carl
snip---



[REBOL] .r monthly calendar improved

2000-02-28 Thread business



; THIS version CORRECTS extra column for months whose first 
day lands at end of week.; also changes name from rebMonth.r to htmMonth.r 
; Please delete the rebMonth.r it's no good.

REBOL [ Title: "HTML Monthly 
Calendar" Date: 19-Feb-2000 Version: 
0.0.2 Name: "Monthly Calendar" 
File: %htmMonth.r Author: "John 
Braman" Email: [EMAIL PROTECTED] 
Rights: { "Copyright (C) John Braman" Permission to use and improve 
granted, 
with the understanding you include my footer on calendar. 
 And if improvements are made please email 
improvements to [EMAIL PROTECTED].} 
Purpose: 
{ 
Prelude to AN INTERACTIVE HTML MONTHLY CALENDAR. 
Currently, using the Rebol Console, you enter 
themonth and year you are interested in.This 
code prints the html version of that month to a file called 
rebolcal.htm " }

Comment: { Thanks to bpaddock, Olivier, Donald 
Dalley, Karin, rryost especially 
Olivier for the slick date coding, and Donald Dalleyand others on list 
who replied to my initial 'prelude to HTML post'.

Ideally future 
versions will be more interactive and completely cgi-enabled with a 
 database or series in flat 
files. However...

I need HELP HERE: The simplest of code that is 
intuitively obvious for veteran Rebols, is new to me.For 
example. I've seen several html-related scripts using an "EMIT" 
function,yet I don't know how it works.

Ideally I'd like to retrieve values from a database or 
at least from a file.Much like I would with coldFusion, PERL, PHP, ASP 
etc. However I've not found clear examples of dbase connection. 
Or even less sophisticated examples of getting data from a file. 
There are too few good examples ofusing REBOL words in the 
dictionary. HELP !For example: What if I had a file with 365+ 
records, many of which will containthe values of holidays and the 
like. The unique key being the date.How do I get data from that file 
via http? How would I write to that file for updates?How 
do I write to that file to update the specific record only using cgi? 
}

 History: [originally called rebMonth.r version 
0.0.1 created 19-2-2000 This version called htmMonth.r created 
27-2-2000] Example: {Show how to use it.}] 
BODY OF CODE FOLLOWS ;; initialize

weekdays: [Sunday Monday Tuesday Wednesday Thursday Friday 
Saturday]; weeks in this calendar start with Monday, if you want them to 
start with any other day then use the series or offset to the appropriate day of 
week. Or change this block to start with the day of the week that you want it 
to.

months: [January February March April May June July August 
September October November December]

; get month and year from useruserDate: PARSE ASK " Enter 
Month as MM , or q to exit : " NONE

IF (first userDate) = "q" [ PRINT "rebMonth.r" HALT ]; use 
appropriate datatypemonth: MAKE INTEGER! FIRST userDateyear: 
MAKE INTEGER! SECOND userDate

; join the input and make it to be the first day of the 
monthinputDate: JOIN 1 [ "-" month "-" year ]firstOfMonth: MAKE DATE! 
inputDate

PRINT ["Do I have it right, the month you are interested in is 
" PICK months(firstOfMonth/month) year"?" NEWLINE "Cancel the write to file and 
re do %htmMonth.r if it's not the right date."]

; find first of next month and first of previous 
month; this will help us to find the number of days in month to make 
calendarfirstOfNextMonth: firstOfMonth/month: firstOfMonth/month + 
1

PRINT ["check again is this the month?" PICK 
months(firstOfMonth/month)]

; find days in month and days in previous month

daysInMonth: firstOfNextMonth - firstOfMonth

; firstOfPrevMonth: firstOfMonth/month: firstOfMonth/month - 
1; there is a bug in the above date function which doesn't work for the 
first month in the year. ; so do a work around.

Either (month = 1) [prevMonthName: 
"December"daysInPrevMonth: 31] 
[firstOfPrevMonth: firstOfMonth/month: firstOfMonth/month - 
1daysInPrevMonth: firstOfMonth - firstOfPrevMonth; convert 
previous month to words and save it.prevMonthName: PICK months 
(firstOfPrevMonth/month)]; end first month bug correction

; convert the month to words, save it.monthName: PICK 
months (month)nextMonthName: PICK months 
(firstOfNextMonth/month)

; print the values just to check themPRINT ["There are " 
daysInPrevMonth " days in " prevMonthName ] ; adjust for first month 
bugPRINT ["There are " daysInMonth " days in " monthName firstOfMonth/year 
]

; is it possible to echo to a port easily for cgi purposes, 
what is the best way if this were running on a server to get the following back 
to the client, after evaluation of course?

ECHO %rebolcal.htm ; write output to a file

; how do I avoid printing to the console?

; HTML header of the calendar page include title and a heading 
with name of month.print "html"print "head"print 
"title REBOL MADE CALENDAR by John Braman's rebMonth.r 
/title"print "/head"print "body"print 
"centerh1font face='Arial' color='BLUE'"print 
[monthName firstOfMonth/year] ; we get month from the inputprint 

[REBOL] envrion var to htm

2000-02-28 Thread business




What is the equivalent rebol expression and word (print, 
write,???) to get the cgi.r program running on the server to 
properlyreturn HTML to the client?

For example,we wantto return the date and time 
(nothing else) on a web page to the client what exactly would acgi 
datetime.rfile contain if it were running on linux/apache 
server?

Also,please provide code for another very useful 
cgiutility and tutorial. Assume we want to show all of 
theenvironment variables on the html paged that is served to the 
client. This is how I would write the script in perl.

#!/usr/local/bin/perl;
print "Content-type: text/html\n\n";

print "HTMLTITLEENV 
Variables/TITLEBODY";

foreach$envirVar (keys %ENV) {
 print "BRFONT 
COLOR=red $envirVar/FONT is set to FONT 
COLOR=green$ENV{$envirVar}/FONT";
}
print "/BODY/HTML";

What does theenviron.rcgi look like in 
Rebol?

AND FINALLY very low priority,

what if I needed to get access to the older style mail telnet 
programs. Wherecurrently using dos or windows... I do the 
following:

telnet://aztec2.asu.edu
login: username
password: letmein
q CR
mail CR

At this point I am asked to enter in the number of the message that I am 
interested in. followed by CR
if the message is more than one page to continue I press space bar,
for the next message it's
n CR

Is any one familiar with this type of mail protocol? 
.




[REBOL] envrion var to htm Re:

2000-02-28 Thread dkirkpatrick



[EMAIL PROTECTED] wrote:
what if I needed to get access to the
older style mail telnet programs. Where currently using dos or windows...
I do the following:telnet://aztec2.asu.edulogin:
usernamepassword: letmeinq CRmail
CRAt this point I am asked to enter in the number
of the message that I am interested in. followed by CRif
the message is more than one page to continue I press space bar,for
the next message it'sn CRIs
any one familiar with this type of mail protocol?

yeah.
its not a protocol.
its the older *nix style POP-client that
pine (mostly) replaced
let me know if you want the unix man page.
I can give you linux, solaris or BSD version.
But I don't want to send it to the entire list





[REBOL] envrion var to htm Re:

2000-02-28 Thread dkirkpatrick



[EMAIL PROTECTED] wrote:

What is the equivalent
rebol expression and word (print, write,???) to get the cgi.r program running
on the server to properly return HTML to the client?For
example, we want to return the date and time (nothing else) on a web page
to the client what exactly would a cgi datetime.r file contain if
it were running on linux/apache server?Also,
please provide code for another very useful cgi utility and tutorial.
Assume we want to show all of the environment variables on the html paged
that is served to the client. This is how I would write the
script in perl.#!/usr/local/bin/perl;print
"Content-type: text/html\n\n";print "HTML>TITLE>ENV
Variables/TITLE>BODY>";foreach $envirVar
(keys %ENV) { print "BR>FONT
COLOR=red> $envirVar/FONT> is set to FONT COLOR=green>$ENV{$envirVar}/FONT>";}print
"/BODY>/HTML>";What does the environ.r
cgi look like in Rebol?AND FINALLY very low
priority,what if I needed to get access to the
older style mail telnet programs. Where currently using dos or windows...
I do the following:telnet://aztec2.asu.edulogin:
usernamepassword: letmeinq CRmail
CRAt this point I am asked to enter in the number
of the message that I am interested in. followed by CRif
the message is more than one page to continue I press space bar,for
the next message it'sn CRIs
any one familiar with this type of mail protocol?.
also, d00d, get rid of the sunOS -
its single threaded. upgrade to Solaris.




[REBOL] Re: [ALLY] [REBOL] Testing REBOL/View Beta List Re:(3)

2000-02-28 Thread carl

Looks like someone messed with SELMA configuration and did not double check it.  The 
original messages are sent to ALLY group of readers but with a [EMAIL PROTECTED] reply 
address.  That's a config error on our part.  Very embarrassing.  Sorry.

-Carl


At 2/28/00 11:45 PM +1000, you wrote:
 
 Does anyone else see this problem?
 
 -Carl

Yes since 25 Feb, all messages for Ally list
have the standard [Ally] subject,
but Return-Path, To and Reply-To are all [EMAIL PROTECTED] 

There are a number of duplicate messages...
Here are a few of duplicates 6764, 6741, 6450, 6798,
(6798 was your post today on the Reb Site Update.)

Cheers,

Allen K
sent to [EMAIL PROTECTED]
 



[REBOL] Split-path correction Re:(4)

2000-02-28 Thread lmecir

Hi,

you wrote:
  There is also others problems with the original split-path:
   split-path http://www.rebol.com
  == [http:// %www.rebol.com]
   split-path http://www.rebol.com/
  == [http:// %www.rebol.com/]
 
  I would prefer to get
  == [http://www.rebol.com/ none]
  in both cases, as in the following:
   split-path %/
  == [%/ none]


the problem is, that your wish cannot be fulfilled, as long, as
you allow all arguments of the type File!, because for File!
values referring to non-existing files, there is no way how to
find out, if:

http://www.nonsense.com/something is a directory. OTOH, the
split-path is (IMHO) meant to work without checking for the
existence of the target, because it should work even for the files
that are not created by that time.

As an additional observation, the Core Dir? is not working
correctly for HTTP URL's. (the reason is similar as for Exists?),
see my solution in that case.

Regards,
Ladislav



[REBOL] Re: envrion var to htm Re:

2000-02-28 Thread alanwall

Hello [EMAIL PROTECTED]

On 28-Feb-00, [EMAIL PROTECTED] wrote:
 në" ë,ýÖ­jÖ©ýʺ-{ÿÖ «b²Ø^z«¢½©^ ÚÞn ^Æ Þ²È¨ ©Ý Ýþ â ßð®+^ÿÿÿþÚÿ ëm ç
 úé® +jjî x§
I have a favor to ask the people who use mailers that also send the mail as
html,could you please turn it off for this list.Thanks! :)
Regards
-- 
JMS Trustee http://www.jms.org
HP=http://www.sonic.net/~alanwall/
First computer solar powered vic-20
AmigaQNX-notAmigaNG=no good
computers for people not suits
sent via Yam ver2 on AmigaForever ver3
Be a Rebel get [EMAIL PROTECTED]



[REBOL] Re: [ALLY] Syntax highlighting...

2000-02-28 Thread reboldes

Hi,
I've just finished the Color coding REBOL scheme for HomeSite (4.0)
written in TSyntaxMemoParser script.

How to install:
1. copy the attached REBOL.scc file into the "Parsers" dir in the
HomeSite tree
2. in the settings (F8) select "Color Coding"
3. select the REBOL scheme
4. and set your own colors (it's up to you which colors and styles
choose)
I know, the default scheme is not good enough.

There is 24 elements containing all Rebol/core commands, words etc., where
you can set styles. (limitation 25 in HS). I will add support for REBOL/VIEW
commands soon.

If you will think that same changes are needed, just let me know and I'll
try to change it.
If you anybody want not compiled script, let me know. I have also a Rebol
script for creating simple TSyntaxMemoParser scripts, but it's a litle bit
not finished (not user friendly enough).

oldes

PS: Is there any editor with syntax highlighting under LINUX?
PPS: Job wanted!

ERIK: where can I find more about Object Edit?

- Original Message -
From: [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Friday, February 18, 2000 10:01 PM
Subject: [ALLY] Syntax highlighting...


 I use Object Edit (great text editor).

 Anyone want to take a stab at creating the rules for REBOL?

 Here is the example file for C.

 -snip---
 [Control]
 Delimiters=():=[];,.{}"'

 [Comments]
 ; FGColor is Maroon
 FGColor=128
 MultiLine-1=/* */
 SingleLine-1=//

 [Strings]
 ; FGColor is the system default, uncomment this to make it BLACK
 ; FGColor=0
 ; MultiLine-1="" ""
 ; MultiLine-2='' ''

 [Keywords-Class-Conditionals]
 ; FGColor is Green
 FGColor=32768
 WordMatch=1
 keylist-d=#define
 keylist-e=#elif #else #endif #error
 keylist-i=#if #ifdef #ifndef #include
 keylist-l=#line
 keylist-p=#pragma
 keylist-u=#undef
 keylist=elif inline warn

 [Keywords-Class-Keywords]
 ; FGColor is Blue
 FGColor=16711680
 WordMatch=1
 keylist-a=asm auto
 keylist-b=break
 keylist-c=case catch cdecl char class const continue
 keylist-d=default delete do double
 keylist-e=else enum extern
 keylist-f=far float for friend
 keylist-g=goto
 keylist-h=huge
 keylist-i=if int interrupt
 keylist-l=long
 keylist-n=near new
 keylist-o=operator
 keylist-p=pascal private protected public
 keylist-r=register return
 keylist-s=short signed sizeof static struct switch
 keylist-t=template this throw try typedef
 keylist-u=union unsigned
 keylist-v=virtual void volatile
 keylist-w=while
 keylist-y=yield

 [Keywords-Class-Defined-Symbols]
 ; FGColor is Red
 FGColor=255
 WordMatch=1
 keylist-f=FALSE
 keylist-n=NULL
 keylist-t=TRUE

 [Keywords-Class-Symbols]
 ; FGColor is Blue
 FGColor=16711680
 WordMatch=0
 keylist=:= = ;   / : ( ) [ ] . , { } * 
 -snip---


 --
 Erik Jorgensen
 Programmer/Analyst - Principle
 Customer Service and Support
 Information  Access Technology Services
 University of Missouri - Columbia
 (573) 882-5974
 www.missouri.edu/~ccjorgie
 [EMAIL PROTECTED]






 REBOL.scc


[REBOL] redirecting input and output Re:

2000-02-28 Thread vddi



[EMAIL PROTECTED] a écrit :

 Hello, and sorry for previous message

 Does anyone know how to use the redirecting input feature of Rebol? I have
 been trying it but it doesn´t seem to work.

 I have tried on Windows things like:

 rebol -w  in  out

 where the file "in" is:

 print "hello!!"

 Redirecting only output works as I expect:

 rebol -w script.r  out

Sorry ! I tried your solution and it worked ! I tried on a MS-DOS console.
I think that :
rebol -w -q in out
is better !

in file contains
print "hello!!"
After out contains exactly 2 lines :
hello!!





[REBOL] Testing REBOL/View Beta List Re:

2000-02-28 Thread icimjs

Hi guys,

Sorry about this noise, I wasn't aware that apparently the problem has been
resolved!


;- Elan  [: - )]



[REBOL] [BUG] unset! (and help function lie!) Re:

2000-02-28 Thread dolmen


- Original Message -
From: [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED]
Sent: Monday, February 28, 2000 3:41 AM
Subject: [REBOL] [BUG] unset! (and "help" function lie!)



 Hi Olivier,

 you wrote:

 So unset! seems to be a datatype.
 Lets verify if unset! is a datatype :
 
  type? file!
 == datatype!
  type? unset!
 ** Script Error: unset! has no value.
 ** Where: type? unset!

 One of REBOL's most confusing issues is that representations of some
values
 look exactly like the words they are assigned to. These values cannot be
 directly parsed by REBOL - first they are parsed to words, and then the
word
 is evaluated.

 When you did:

  type? file!
 == datatype!

 REBOL first parsed the string you typed, "file!", to the word file!, and
 then when that word is used as the argument of TYPE? it is evaluated. The
 word FILE! is preset to the datatype! file!, which is the value that the
 function TYPE? sees.


I had no problem with that.
My point was that unset! is not preset to any value.

[...]

 Now the problem with unset! is that there is no word set to the value
 unset! . This is easily fixed:

  unset: (type?)
 == unset!
  type? unset!
 == datatype!


Of course. I should have thought to this.


 I put the paren around type? because if you do this in a script TYPE? will
 take the value of whatever is next, but the paren prevents TYPE? from
seeing
 anything else.


 You also wrote:

  type? file!
 == datatype!
  help file!
 file! is word of value: file
 
 This not ok!

 It seems inconsistent, but this is the result of a REBOL trick. HELP has a
 special way of specifying its argument:


I'm writing this kind of messages to [EMAIL PROTECTED] not to get a
work-around, but for them to make it consistent while REBOL is still not
widely spread.

 help: func [
 "Prints information about words and values."
 'word [any-type!]
 /local value args item refmode types
 ][
 snip
 ]

 The argument is specified as a lit-word! (by using the ' ). This specifies
 that if the argument is actually a word, that word is to be unevaluated.

Thanks for this explanation. Passing parameters as lit-word! is a very cool
feature.

 That is, HELP wants to see the word itself, not what the word is set to.
 This way you can use HELP to test if a word is set to a value:

  help grog
 No information on grog (word has no value)

 Otherwise, trying to evaluate the word grog would result in an error
 before HELP even had a chance to see it.

 So, if you want to get help on the value that the word is set to, try
this:

  help (file!)
 file! is datatype
  help file!
 file! is word of value: file

 Putting the word file! in a paren prevents HELP from seeing it as a word.
 So the paren is evaluated, the datatype! file! comes out, and HELP
 tells you that the datatype! file! is a datatype.

We also get the same result with the following the ':' operator :
 help :file!
file! is datatype

This is what I expected from
 help file!

(without using :)


I just wanted that they modify the 'help' function to be more informative
about datatypes.


 One other little issue here is that there are two ways of representing a
 value, forming and molding. Molding is better in that it gives you a
string
 that REBOL can use to get back the original value, but forming is supposed
 to be easier on the eye. HELP forms the values, which is why you lose
 the ! 's.


 See you,
 Eric


With all those good explanations on the heart of the language, it's now time
for me to re-read the REBOL user guide from the beginning, to understand
every feature.

Thanks Eric.





[REBOL] [ally] confusion Re:

2000-02-28 Thread syndrome



[EMAIL PROTECTED] wrote:
 
 Looks like someone messed with SELMA configuration and did not double check it.  The 
original messages are sent to ALLY group of readers but with a [EMAIL PROTECTED] reply 
address.  That's a config error on our part.  Very embarrassing.  Sorry.
 
 -Carl


Well, perhaps the members of the beta list find this annoying, and maybe
even some people who are just on the main list - but I for one am
grateful for every scrap and morsel from the ally list that comes my way
:)

Chris



[REBOL] user defined datatypes?

2000-02-28 Thread anton_rolls

Hi,

Is there a way to create user defined datatypes?
For example sample!

I've tried a few things but can't seem to figure it out.
Could someone point me to any existing docs on it?

Thanks,
Anton.



[REBOL] user defined datatypes? Re:

2000-02-28 Thread Al . Bri

Anton wrote:
 Is there a way to create user defined datatypes?
 For example sample!

There isn't a way at the moment, that I know of.
Objects have some of the functionality that you require.

Andrew Martin
ICQ: 26227169
http://members.xoom.com/AndrewMartin/
--



[REBOL] txt only .r html calendar sorry :/

2000-02-28 Thread business


psss, were the html tags a bit thick last time... sorry :-\ .

; THIS version CORRECTS extra column for months whose first day lands at end
of week.
; also changes name from rebMonth.r to htmMonth.r
; Please delete the rebMonth.r it's no good.


REBOL [
   Title:  "HTML Monthly Calendar"
   Date:   19-Feb-2000
   Version: 0.0.2
   Name:   "Monthly Calendar"
   File:   %htmMonth.r
   Author: "John Braman"
   Email:  [EMAIL PROTECTED]
   Rights: { "Copyright (C) John Braman" Permission to use and improve
granted,
 with the understanding you include my footer on calendar.
  And if improvements are made please email improvements to
[EMAIL PROTECTED]
 }
   Purpose: {
   Prelude to AN INTERACTIVE HTML MONTHLY CALENDAR.
  Currently, using the Rebol Console, you enter the
  month and year you are interested in.
  This code prints the html version of that month
  to a file called rebolcal.htm "
  }

 Comment: { Thanks to  bpaddock, Olivier, Donald Dalley, Karin, rryost
especially Olivier for the slick date coding, and Donald Dalley
 and others on list who replied to my initial 'prelude to HTML post'.

Ideally future versions will be more interactive and completely
cgi-enabled with a
database or series in flat files.  However...

 I need HELP HERE:  The simplest of code that is intuitively obvious for
 veteran Rebols, is new to me.
 For example.  I've seen several html-related scripts using an "EMIT"
function,
 yet I don't know how it works.

 Ideally I'd like to retrieve values from a database or at least from a
file.
 Much like I would with coldFusion, PERL, PHP, ASP etc. However I've not
 found clear examples of dbase connection.  Or even less sophisticated
 examples of getting data from a file.  There are too few good examples of
 using REBOL words in the dictionary.  HELP !
 For example: What if I had a file with 365+ records, many of which will
contain
 the values of holidays and the like. The unique key being the date.
 How do I get data from that file via http?  How would I write to that file
for  updates?
 How do I write to that file to update the specific record only using cgi?
 }

   History: [originally called rebMonth.r version 0.0.1 created 19-2-2000
This version called htmMonth.r created 27-2-2000]
   Example: {Show how to use it.}
]
 BODY OF CODE FOLLOWS ;
; initialize

weekdays: [Sunday Monday Tuesday Wednesday Thursday Friday Saturday]
; weeks in this calendar start with Monday, if you want them to start with
any other day then use the series or offset to the appropriate day of week.
Or change this block to start with the day of the week that you want it to.

months: [January February March April May June July August September October
November December]

; get month and year from user
userDate: PARSE ASK " Enter Month as MM , or q to exit : " NONE

IF (first userDate) = "q" [ PRINT "rebMonth.r" HALT ]
; use appropriate datatype
month:   MAKE INTEGER! FIRST userDate
year: MAKE INTEGER! SECOND userDate

; join the input and make it to be the first day of the month
inputDate: JOIN 1 [ "-" month "-" year ]
firstOfMonth: MAKE DATE! inputDate

PRINT ["Do I have it right, the month you are interested in is " PICK
months(firstOfMonth/month) year"?" NEWLINE "Cancel the write to file and re
do %htmMonth.r if it's not the right date."]


; find first of next month and first of previous month
; this will help us to find the number of days in month to make calendar
firstOfNextMonth: firstOfMonth/month: firstOfMonth/month + 1

PRINT ["check again is this the month?" PICK months(firstOfMonth/month)]

; find days in month and days in previous month

daysInMonth: firstOfNextMonth - firstOfMonth

; firstOfPrevMonth: firstOfMonth/month: firstOfMonth/month - 1
; there is a bug in the above date function which doesn't work for the first
month in the year.
; so do a work around.

Either (month = 1) [
 prevMonthName: "December"
 daysInPrevMonth: 31
 ]
 [
 firstOfPrevMonth: firstOfMonth/month: firstOfMonth/month - 1
 daysInPrevMonth: firstOfMonth - firstOfPrevMonth
 ; convert previous month to words and save it.
 prevMonthName: PICK months (firstOfPrevMonth/month)
 ]; end first month bug correction

; convert the month to words, save it.
monthName: PICK months (month)
nextMonthName: PICK months (firstOfNextMonth/month)

; print the values just to check them
PRINT ["There are " daysInPrevMonth " days in " prevMonthName ] ; adjust for
first month bug
PRINT ["There are " daysInMonth " days in " monthName firstOfMonth/year ]

; is it possible to echo to a port easily for cgi purposes, what is the best
way if this were running on a server to get the following back to the
client, after evaluation of course?

ECHO  %rebolcal.htm ; write output to a file


; how do I avoid printing to the console?

; HTML header of the calendar page include title and a heading with name of
month.
print "html"
print "head"
print "title REBOL MADE CALENDAR by 

[REBOL] Parsing and Recursion [REPOST]

2000-02-28 Thread mdb



*** REPOSTING 
***

Hello,I'm having a problem with 
understanding Parsing using recursion. The codebelow consists of 4 tests. 
Tests 1 and 4 produce the correct results, both in terms of the values 
inthe block and that they returns TRUE. The [none] in the rule makes 
thishappen.Test 2 produces the correct values in the block but 
returns FALSE,presumably because [none] is missing from the 
rule.However why does Test 3 return TRUE but process the last input 
valuetwice??Mike.REBOL []check: 
func [] [clear inpsprobe parse "123+" colprint inpsclear 
inpsprobe parse "123+456-" colprint inps]inps: []digits: 
charset "0123456789"num: [copy value [some digits] (value: 
to-decimal value)]term: [num ["+" (insert tail inps value)|"-" (insert tail 
inps negatevalue)]];Test 1print "Test 1"col: [term col | 
[none]]check;Test 2print "Test 2"col: [term 
col]check;Test 3print "Test 3"col: [term col | 
term]check;Test 4print "Test 4"col: [term col | term | 
[none]]check


[REBOL] Ally list

2000-02-28 Thread deadzaphod

How do I subscribe to the ALLY list?  I've been playing with the REBOL/View 
beta, but I don't know how to get on the list to discuss it.. really 
frustrating...
TIA,

Cal Dixon ([EMAIL PROTECTED])
--

__
Get Your Private, Free Email at http://www.hotmail.com



[REBOL] [REBOL] Connection timing

2000-02-28 Thread cplp

Newbie question:

I have 14 URLs that I can connect to. I want to know which ones (I need to
2, one for upstream and one for downstream) are giving the best speeds. The
destinations are (in this case) in the US and I'm in Pakistan. How do I do
it?

Bruce.