Hi,
Another handy use of cl-who is to generate xml testing data, like so:
(with-html (loop repeat 500 do (htm (:|Item| (:|ASIN| (str (format nil "~D" (random 9999999999)))) (:|DetailPageURL| "http://www.amazon.com/") (:|ItemAttributes| (:|Author| (str (conc (random-word) " " (random-word)))) (:|Manufacturer| (str (random-word))) (:|ProductGroup| (str (random-word))) (:|Title| (str (conc (random-word) " " (random-word)" " (random-word)))))))))
Attached is a simple patch to introduce a special var cl-who:*downcase-tag* to control whether cl-who should downcase tagname by default.
Originally I thought just using the (eql *html-mode* :xml) test should be sufficient. But I see that a lot of people actually only use lowercase xml tags for internal projects and requiring them to quote a symbol with :|| is kind of inconvenient.
Cheers, -- Mac
On Mon, 19 Mar 2007 17:00:35 -0700, "Mac Chan" emailmac@gmail.com wrote:
Another handy use of cl-who is to generate xml testing data, like so:
(with-html (loop repeat 500 do (htm (:|Item| (:|ASIN| (str (format nil "~D" (random 9999999999)))) (:|DetailPageURL| "http://www.amazon.com/") (:|ItemAttributes| (:|Author| (str (conc (random-word) " " (random-word)))) (:|Manufacturer| (str (random-word))) (:|ProductGroup| (str (random-word))) (:|Title| (str (conc (random-word) " " (random-word)" " (random-word)))))))))
Attached is a simple patch to introduce a special var cl-who:*downcase-tag* to control whether cl-who should downcase tagname by default.
Originally I thought just using the (eql *html-mode* :xml) test should be sufficient. But I see that a lot of people actually only use lowercase xml tags for internal projects and requiring them to quote a symbol with :|| is kind of inconvenient.
Thanks. I can't apply the patch, though. Can you send the output of "diff -u" please?
Thanks, Edi.
On Mon, 19 Mar 2007 17:00:35 -0700, "Mac Chan" emailmac@gmail.com wrote:
Another handy use of cl-who is to generate xml testing data, like so:
(with-html (loop repeat 500 do (htm (:|Item| (:|ASIN| (str (format nil "~D" (random 9999999999)))) (:|DetailPageURL| "http://www.amazon.com/") (:|ItemAttributes| (:|Author| (str (conc (random-word) " " (random-word)))) (:|Manufacturer| (str (random-word))) (:|ProductGroup| (str (random-word))) (:|Title| (str (conc (random-word) " " (random-word)" " (random-word)))))))))
Attached is a simple patch to introduce a special var cl-who:*downcase-tag* to control whether cl-who should downcase tagname by default.
Thanks, I've now released a new version which incorporates your patch.