Wayne Pierce wrote:

> REBOL[]
>
> (1) page: {
> <HTML>
>  <HEAD>
>   <TITLE></TITLE>
>  </HEAD>
>  <BODY>
>   <SELECT>}
>
> (2) options: read %options.txt
>
> (3) options: parse options none
>
> (4) body: []
>
> (5) disarm try[ while [length? options][
>    (6) append body join "<OPTION>'" join first options join "'</OPTION>"
> join second options #"^/"
>    (7) remove head options
>    (7) remove head options
> ]]
>
> (8) append page body
> (9) append page {</SELECT></BODY></HTML>}

Better might be:

[
Rebol []

Page: make block! 0

insert head Page [
    <html> <head> <title> "Insert your Page title here" </title> <body>
<select>
    ]

foreach [Value Text] parse read %Options.txt none [
    append Page reduce [
        <option> Value </option> Text newline
        ]
    ]

append Page [
    </select> </body> </html>
    ]
write %YourFileNameHere.html join "" Page
]

Or using my HTML dialect:

[
Rebol []
do %HTML.r
write %YourFileNameHere.html HTML [
    title "Insert your Page title here"
    body
    h1 "Insert your Page title here"
    select load %Options.txt
    ]
]

I hope that helps!

Andrew Martin
ICQ: 26227169
http://members.nbci.com/AndrewMartin/
-><-


-- 
To unsubscribe from this list, please send an email to
[EMAIL PROTECTED] with "unsubscribe" in the 
subject, without the quotes.

Reply via email to