parse, I think, (again)
[1/2] from: balayo:mindspring at: 30-Sep-2000 20:18
hey guys,
sorry about that blank post.
If given a block, ["text, text -b text --b , text"],
how do I replace -b and --b with <b> and </b>, respectively?
--
Turn your computer off. Go outside.
-tom
[2/2] from: al::bri::xtra::co::nz at: 30-Sep-2000 22:25
tom wrote:
> If given a block, ["text, text -b text --b , text"],
> how do I replace -b and --b with <b> and </b>, respectively?
This is the most direct way:
>> block: ["text, text -b text --b , text"]
== ["text, text -b text --b , text"]
>> string: copy first block
== "text, text -b text --b , text"
>> replace/all string "--b" "</b>"
== "text, text -b text </b> , text"
>> replace/all string "-b" "<b>"
== "text, text <b> text </b> , text"
Easy is:
>> do %html.r
>> block: [body "text, text " bold "text" ", text"]
== [body "text, text " bold "text" ", text"]
>> HTML block
== {<html>
<head>
</head>
<body>
text, text <b>text</b>, text</body>
</html>
}
YMMV.
Andrew Martin
ICQ: 26227169
http://members.nbci.com/AndrewMartin/
http://members.xoom.com/AndrewMartin/