Back

html4 (clj)

(source)

macro

(html4 & contents)
Create a HTML 4 document with the supplied contents. The first argument may be an optional attribute map.

Examples

hiccup
(ns hiccup.page_test
  (:require [clojure.test :refer :all]
            [hiccup.page :refer :all])
  (:import java.net.URI))

(deftest html4-test
  (is (= (html4 [:body [:p "Hello" [:br] "World"]])
         (str "<!DOCTYPE html PUBLIC \"-//W3C//DTD HTML 4.01//EN\" "
              "\"http://www.w3.org/TR/html4/strict.dtd\">\n"
              "<html><body><p>Hello<br>World</p></body></html>"))))
weavejester/hiccup
(ns hiccup.page_test
  (:require [clojure.test :refer :all]
            [hiccup.page :refer :all])
  (:import java.net.URI))

(deftest html4-test
  (is (= (html4 [:body [:p "Hello" [:br] "World"]])
         (str "<!DOCTYPE html PUBLIC \"-//W3C//DTD HTML 4.01//EN\" "
              "\"http://www.w3.org/TR/html4/strict.dtd\">\n"
              "<html><body><p>Hello<br>World</p></body></html>"))))