legacy-dotfiles/emacs.d/nxhtml/tests/in/chunks.html
Tom Willemsen 94d2fc1815 Django, org
* Added nxhtml, mostly for django support.

  * Changed some org settings.
2011-03-07 09:04:49 +01:00

63 lines
2.5 KiB
HTML

<?xml version="1.0" encoding="iso-8859-1"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title></title>
<script type="text/javascript">
// <![CDATA[
alert ("here");
/*
--------------------------------------------------------------------------
Do not edit past this point unless you know what you are doing.
--------------------------------------------------------------------------
===== BUG: THIS LINE IS BLACK ==========
===== BUG: THIS LINE IS BLACK ==========
*/
addEvent(window, 'load', spamSpan);
function spamSpan() {
var allSpamSpans = getElementsByClass(spamSpanMainClass, document, 'span');
for (var i = 0; i < allSpamSpans.length; i++) {
// get data
var user = getSpanValue(spamSpanUserClass, allSpamSpans[i]);
var domain = getSpanValue(spamSpanDomainClass, allSpamSpans[i]);
var anchorText = getSpanValue(spamSpanAnchorTextClass, allSpamSpans[i]);
// prepare parameter data
var paramValues = new Array();
for (var j = 0; j < spamSpanParams.length; j++) {
var paramSpanValue = getSpanValue(spamSpanParams[j], allSpamSpans[i]);
if (paramSpanValue) {
paramValues.push(spamSpanParams[j] + '=' +
encodeURIComponent(paramSpanValue));
}
}
// create new anchor tag
var at = String.fromCharCode(32*2);
var email = cleanSpan(user) + at + cleanSpan(domain);
var anchorTagText = document.createTextNode(anchorText ? anchorText : email);
var mto = String.fromCharCode(109,97,105,108,116,111,58);
var hrefAttr = mto + email;
hrefAttr += paramValues.length ? '?' + paramValues.join('&') : '';
var anchorTag = document.createElement('a');
anchorTag.className = spamSpanMainClass;
anchorTag.setAttribute('href', hrefAttr);
anchorTag.appendChild(anchorTagText);
// replace the span with anchor
allSpamSpans[i].parentNode.replaceChild(anchorTag, allSpamSpans[i]);
}
}
// ]]>
</script>
<style type="text/css" media="all">
/* <![CDATA[ */
body {
margin-left: 1px;
/* ]]> */
</style>
</head>
<body>
</body>
</html>