This is a list of features you can allow when using the sanitizedHtml function.
The things to allow in links, images, css, and aother urls. FIXME: implement this for better flexibility
Adds some script to run onload FIXME: not implemented
Returns true of the string appears to be html/xml - if it matches the pattern for tags or entities.
Translates nested css
Get the favicon out of a document, or return the default a browser would attempt if it isn't there.
Given arbitrary user input, find links and add <a href> wrappers, otherwise just escaping the rest of it for HTML display.
Convenience function to create a small <form> to POST, but the creation function is more like a link than a DOM form.
Similar to the above, but lets you pass HTML rather than just text. It puts the html inside a <button type="submit"> element.
Like the Html overload, this uses a <button> tag to get fancier with the submit button. The element you pass is appended to the submit button.
Given an existing link, create a POST item from it. You can use this to do something like:
Given user text, converts newlines to <br> and encodes the rest.
Given existing encoded HTML, turns \n\n into <p>.
This returns an element wrapping sanitized content, using a whitelist for html tags and attributes, and a blacklist for css. Javascript is never allowed.
makes input[type=date] to call displayDatePicker with a button
tries to make an input to filter a list. it kinda sucks.
find <input> elements with a title. Make the title the default internal content
finds class="striped" and adds class="odd"/class="even" to the relevant children
Translates validate="" tags to inline javascript. "this" is the thing being checked.
This wraps every non-empty text mode in the document body with <t:t></t:t>, and sets an xmlns:t to the html root.
This is some basic CSS I suggest you copy/paste into your stylesheet if you use the sanitizedHtml function.
This module includes functions to work with HTML and CSS in a more specialized manner than arsd.dom. Most of this is obsolete from my really old D web stuff, but there's still some useful stuff. View source before you decide to use it, as the implementations may suck more than you want to use.
It publically imports the DOM module to get started. Then it adds a number of functions to enhance html DOM documents and make other changes, like scripts and stylesheets.