Curl/示例 2
外观
< Curl
{curl 5.0, 6.0 applet} || an example in the declarative style {Table {row-prototype "Name", "Description", "Cost"}, {row-prototype "Apple", "A red fruit", "25"}, {row-prototype "Banana", "A yellow fruit", "25"}, {row-prototype "Orange", "A reddish-yellow fruit", "50"} } |* Another way to comment This is HTML to do the same thing <HTML> <BODY> <TABLE> <tr><td>Name</td><td>Description</td><td>Cost</td></tr> <tr><td>Apple</td><td>A red Fruit</td><td>25</td></tr> <tr><td>Banana</td><td>A yellow fruit</td><td>25</td></tr> <tr><td>Orange</td><td>A reddish-yellow fruit</td><td>50</td>< /tr> </TABLE> </BODY> </HTML> *|
此代码显示一个表格,就像注释中的声明性 HTML 一样。
第 1-4 行是标准的。
第 5 行声明一个新表格。
第 6-9 行将值放入四行中
第 10 行结束表格。