michaelfox + markup   29

padraic/wibble
Experiment for: Zend Framework HTML Sanitiser/Manipulator
php  inspiration  zend  html  sanitiser  parser  formatter  regex  clean  security  markup  input 
15 days ago by michaelfox
MultiMarkdown
Go to the downloads page on github to find the latest versions of:

MultiMarkdown installer for Mac OS X
MMD support files installer for Mac OS X
QuickLook generator for MMD text files and for OPML files
Mac OS X drag and drop applications for MMD
MultiMarkdown installer for Windows
latest source code to compile MMD yourself (e.g. for *nix)
If you are interested in the LaTeX features, you also download the LaTeX support files on github.

You can also download:

LaTeX support files — required for compiling the sample documents, and useful for your own documents

MultiMarkdown Test Suite for developers

A gallery of sample MultiMarkdown documents demonstrating various output formats and features

A MMD bundle for TextMate

A MMD export plug-in for OmniOutliner

The MMD support files for other systems
downloads  latex  markdown  textmate  markup  tools  osx 
june 2011 by michaelfox
Pandoc - About pandoc
If you need to convert files from one markup format into another, pandoc is your swiss-army knife. Need to generate a man page from a markdown file? No problem. LaTeX to Docbook? Sure. HTML to MediaWiki? Yes, that too. Pandoc can read markdown and (subsets of) reStructuredText, textile, HTML, and LaTeX, and it can write plain text, markdown, reStructuredText, HTML, LaTeX, ConTeXt, PDF, RTF, DocBook XML, OpenDocument XML, ODT, GNU Texinfo, MediaWiki markup, textile, groff man pages, Emacs org-mode, EPUB ebooks, and S5 and Slidy HTML slide shows. PDF output (via LaTeX) is also supported with the included markdown2pdf wrapper script.

Pandoc understands a number of useful markdown syntax extensions, including document metadata (title, author, date); footnotes; tables; definition lists; superscript and subscript; strikeout; enhanced ordered lists (start number and numbering style are significant); delimited code blocks; markdown inside HTML blocks; and TeX math. Other options include “smart” punctuation, syntax highlighting, automatically generated tables of contents, and automatically generated citations (using citeproc-hs). If strict markdown compatibility is desired, all of these extensions can be turned off with a command-line flag.

Pandoc includes a Haskell library and a standalone executable. The library includes separate modules for each input and output format, so adding a new input or output format just requires adding a new module.
html  latex  markdown  markup  pdf  textile  text  convert  docbook 
april 2011 by michaelfox
Make.text
javascript:(function(){/** Make.text 1.5. Trevor Jim. License: GPL v2 (www.fsf.org/copyleft/gpl.html). **/ var logging = false; var logString = ''; var unhandled = {}; function log(exn,msg) { if (!logging) return; logString += msg + ': ' + exn + '%5cn'; } var w = window.open(''); var d = w.document; var last = null; function addText(s) { if (last != null) d.write(last); last = s; } function llapLast(s) { if (last) last = last.replace(/ $/,s); } function finishOutput() { addText(%22%22); } var links = new Array(window.location); var rlinks = {}; rlinks[window.location] = 0; var linkTitles = new Array(); var atP = true; var atLeft = true; var atNoWS = true; var left = '%5cn'; function pushLeft(s) { var oldLeft = left; left += s; if (atP) addText(s); else p(); function r() { left = oldLeft; atP = atLeft = false; p(); } return r; } function p() { if (atP) return; if (!atLeft) { addText(left); atLeft = true; } addText(left); atP = atNoWS = true; } function llap(s) { if (!atLeft) { addText(left.replace(/ $/,s)); atLeft = atP = atNoWS = true; return; } else { llapLast(s); return; } } function br(s) { addText(' ' + left); atLeft = atNoWS = true; } function o(s) { if (!s) return; if (!inPRE) { if (atNoWS) s = s.replace(/^[ %5ct%5cn]+/,''); else if (/^[ %5ct]*%5cn/.test(s)) s = s.replace(/^[ %5ct%5cn]+/,'%5cn'); else s = s.replace(/^[ %5ct]+/,' '); } if (s == '') return; atP = /%5cn%5cn$/.test(s); atLeft = /%5cn$/.test(s); atNoWS = /[ %5ct%5cn]$/.test(s); addText(s.replace(/%5cn/g,left)); } function oThunk(s) { function r() { o(s); } return r; } var inPRE = false; function pre() { var old = inPRE; inPRE = true; function r() { inPRE = old; } return r; } var inCODE = false; function code() { var old = inCODE; inCODE = true; function r() { inCODE = old; } return r; } var inOL = false; function ol() { var old = inOL; inOL = true; function r() { inOL = old; } return r; } function ul() { var old = inOL; inOL = false; function r() { inOL = old; } return r; } var replacements = { '%5c%5c%5c%5c': '%5c%5c%5c%5c', '%5c%5c[': '%5c%5c[', '%5c%5c]': '%5c%5c]', '>': '%5c%5c>', '_': '%5c%5c_', '%5c%5c*': '%5c%5c*', '`': '%5c%5c`', '#': '%5c%5c#', '([0-9])%5c%5c.(%5c%5cs|$)': '$1%5c%5c.$2', '%5cu00a9': '(c)', '%5cu00ae': '(r)', '%5cu2122': '(tm)', '%5cu00a0': ' ', '%5cu00b7': '%5c%5c*', '%5cu2002': ' ', '%5cu2003': ' ', '%5cu2009': ' ', '%5cu2018': %22'%22, '%5cu2019': %22'%22, '%5cu201c': '%22', '%5cu201d': '%22', '%5cu2026': '...', '%5cu2013': '--', '%5cu2014': '---' }; var regex = {}; for (var key in replacements) { regex[key] = new RegExp(key, 'g'); } function nonPREproc(s) { s = s.replace(/%5cn([ %5ct]*%5cn)+/g,'%5cn'); s = s.replace(/%5cn[ %5ct]+/g,'%5cn'); s = s.replace(/[ %5ct]+/g,' '); for (var key in replacements) { s = s.replace(regex[key], replacements[key]); } return s; } function inCODEproc(s) { s = s.replace(/`/g,'%5c%5c`'); return s; } function isAbsolute(s) { return /^[a-zA-Z]([a-zA-Z0-9+-.])*:/.test(s); } function isSiteRelative(s) { return /^%5cx2f/.test(s); } function isPageRelative(s) { return /^#/.test(s); } var urlBase = location.href; var urlDir = urlBase.replace(/%5c/[^%5c/]*$/,'/'); var urlPage = urlBase.replace(/#[^%5c/#]*$/,''); var urlSite = urlBase; if (isAbsolute(urlBase)) { urlSite = urlBase.replace(/^([a-zA-Z]([a-zA-Z0-9+-.])*:%5c/%5c/[^%5c/]*).*/,'$1'); } function makeAbsolute(s) { if (isAbsolute(s)) return s; else if (isSiteRelative(s)) return urlSite + s; else if (isPageRelative(s)) return urlPage + s; else return urlDir + s; } function urlEscape(s) { s = makeAbsolute(s); s = s.replace(/%5cx22/g,'%2522'); s = s.replace(/%5cx27/g,'%2527'); s = s.replace(/%5cx20/g,'%2520'); s = s.replace(/%5cx09/g,'%2509'); s = s.replace(/%5cx0a/g,'%250a'); s = s.replace(/%5cx0d/g,'%250d'); s = s.replace(/%5cx28/g,'%2528'); s = s.replace(/%5cx29/g,'%2529'); s = s.replace(/%5cx5b/g,'%255b'); s = s.replace(/%5cx5d/g,'%255d'); s = s.replace(/%5cx5c/g,'%255c'); return s; } if (!window.Node) Node = {}; if (!Node.ELEMENT_NODE) Node.ELEMENT_NODE = 1; if (!Node.TEXT_NODE) Node.TEXT_NODE = 3; function dfs(e) { if (window.getComputedStyle) { try { var style = window.getComputedStyle(e,null); if (style.getPropertyValue %26%26 style.getPropertyValue('display') == 'none') return; } catch (exn) { log(exn,'computedStyle'); } } if (e.nodeType == Node.ELEMENT_NODE) { var after = null; var skipChildren = false; try { switch (e.tagName) { case 'HEAD': case 'STYLE': case 'SCRIPT': case 'SELECT': case 'OPTION': case 'NOSCRIPT': case 'NOFRAMES': case 'INPUT': case 'BUTTON': case 'SELECT': case 'TEXTAREA': case 'LABEL': skipChildren = true; break; case 'BODY': case 'FORM': break; case 'H1': p(); o('# '); break; case 'H2': p(); o('## '); break; case 'H3': p(); o('### '); break; case 'H4': p(); o('#### '); break; case 'H5': p(); o('##### '); break; case 'H6': p(); o('###### '); break; case 'P': p(); break; case 'DIV': p(); break; case 'BR': br(); break; case 'HR': p(); o('--------------------------------'); p(); break; case 'EM': case 'I': case 'U': o('_'); atNoWS = true; after = oThunk('_'); break; case 'DT': p(); case 'STRONG': case 'B': o('**'); atNoWS = true; after = oThunk('**'); break; case 'OL': var r1 = pushLeft(' '); var r2 = ol(); after = function() { r1(); r2(); }; break; case 'UL': var r1 = pushLeft(' '); var r2 = ul(); after = function() { r1(); r2(); }; break; case 'LI': if (inOL) llap('1. '); else llap('* '); break; case 'PRE': var r1 = pushLeft(' '); var r2 = pre(); after = function() { r1(); r2(); }; break; case 'CODE': if (!inPRE) { o('`'); var r1 = code(); var r2 = oThunk('`'); after = function() { r1(); r2(); }; } break; case 'DD': case 'BLOCKQUOTE': after = pushLeft('> '); break; case 'A': var href = e.getAttribute('href'); if (!href) break; href = urlEscape(href); var n; if (rlinks[href]) { n = rlinks[href]; } else { n = links.length; links[n] = href; rlinks[href] = n; if (e.getAttribute('title')) linkTitles[n] = e.getAttribute('title'); } o('['); atNoWS = true; after = oThunk('][' + n + ']'); break; case 'IMG': skipChildren = true; var src = e.getAttribute('src'); if (!src) break; src = urlEscape(src); var alt = e.getAttribute('alt'); if (!alt) alt = ''; o('![' + alt + '](' + src + ')'); break; case 'IFRAME': case 'FRAME': skipChildren = true; try { if (e.contentDocument %26%26 e.contentDocument.documentElement) { dfs(e.contentDocument.documentElement); } } catch (exn) { log(exn,'contentDocument'); } break; case 'TR': after = p; break; default: if (logging) unhandled[e.tagName] = null; break; } } catch (exn) { log(exn,e.tagName); } if (!skipChildren) { var c = e.childNodes; for (var i = 0; i < c.length; i++) { dfs(c[i]); } } if (after) after(); } else if (e.nodeType == Node.TEXT_NODE) { if (inPRE) o(e.nodeValue); else if (inCODE) o(inCODEproc(e.nodeValue)); else o(nonPREproc(e.nodeValue)); } } addText('<pre>'); addText('%26lt;!-- [' + window.document.title + '][0] --%26gt;%5cn%5cn'); dfs(window.document.body); addText('%5cn%5cn'); for (var i = 0; i < links.length; i++) { var title = '%5cn'; if (linkTitles[i]) title = ' %22' + linkTitles[i] + '%22%5cn'; if (links[i]) addText('[' + i + ']: ' + links[i] + title); } if (logging) { addText('%5cn%5cn%26lt;!-- Make.text debugging:%5cn'); for (var i in unhandled) addText('Not handled: ' + i + '%5cn'); addText('%5cn'); addText(logString); addText('--%26gt;%5cn'); } addText('</pre>'); finishOutput(); d.close(); })();void(0);
html  javascript  markdown  markup  convert  format  bookmarklets 
february 2011 by michaelfox
Link Relations
alternate, appendix, bookmark, chapter, contents, copyright, current, describedby, edit, edit-media, enclosure, first, glossary, help, hub, index, last, latest-version, license, monitor, monitor-group, next, next-archive, payment, predecessor-version, prev, previous, prev-archive, related, replies, section, self, service, start, stylesheet, subsection, successor-version, up, version-history, via, working-copy, working-copy-of
link  releation  rel  html  html5  semantic  href  microdata  microformats  metadata  data  rdf  markup  seo  reference  resources 
october 2010 by michaelfox
Rich snippets testing tool - Webmaster Tools Help
Rich snippets testing tool
Share

* Twitter
* Gmail
* Blogger
* Buzz
* Orkut
* Google Reader
* Bookmarks
* » More

Comment Print

The rich snippets testing tool lets you check your markup and make sure that Google can extract the structured data from your page. This tool will display the markup found on a specific web page, as well as a preview of how that page might appear in Google search results.

This tool is still a work in progress, so there are a few points to note:

* The tool doesn't currently display a preview of breadcrumbs content. We're working on it!
* The tool interface is currently available in English only. The tool will correctly test markup in other languages; however, the results will not look like they will look in an actual non-English search results page.
* The tool will only display extracted information that is officially supported for rich snippets. Supported RDFa attributes are xmlns, typeof, property, rel, and content.

"Insufficient data to generate preview"

In general, the goal of rich snippets is to display the most relevant content on the page to users. If you see an "insufficient data to generate preview" message, it is generally for one of two reasons:

* The marked-up content doesn't appear to be the main subject of the page. This can happen if the marked-up content is very low down on the page, is found in boilerplate elements such as headers, footers, and navigation, or is included in a hidden HTML element.
* The marked-up content is missing important tags. For example, a Person item must include organization, location, or role, as well as name.

This is an early release of the testing tool, and feedback is welcome. Please submit feedback or bugs on the Webmaster Tools forum. For tips and tricks, check out the Rich snippets knol (English only).
markup  microformats  search  rdfa  resources  google  seo  semantic  semantics  html  html5  data  microdata 
october 2010 by michaelfox
Rich snippets (microdata, microformats, RDFa) - Webmaster Tools Help
Rich snippets (microdata, microformats, RDFa)

o Rich snippets (microdata, microformats, and RDFa)
o Breadcrumbs
o About microdata
o About microformats
o About RDFa
o Nested items
o Recipes
o Reviews
o Review ratings
o People
o Events
o Businesses and organizations
o Products
o Videos: Facebook Share and RDFa
o Rich snippets testing tool
markup  microformats  search  rdfa  reference  resources  google  seo  semantic  semantics  html  html5  data  microdata  semanticweb  snippets 
october 2010 by michaelfox
Breadcrumbs - Webmaster Tools Help
<div itemscope itemtype="http://data-vocabulary.org/Breadcrumb"> <a href="http://www.example.com/dresses" itemprop="url"> <span itemprop="title">Dresses</span> </a> › </div> <div itemscope itemtype="http://data-vocabulary.org/Breadcrumb"> <a href="http://www.example.com/dresses/real" itemprop="url"> <span itemprop="title">Real Dresses</span> </a> › </div> <div itemscope itemtype="http://data-vocabulary.org/Breadcrumb"> <a href="http://www.example.com/clothes/dresses/real/green" itemprop="url"> <span itemprop="title">Real Green Dresses</span> </a> </div>
breadcrumbs  semantics  semantic  markup  microdata  data  html  html5  seo  google 
october 2010 by michaelfox
HTML5 Microdata: Welcome to the Machine | Nettuts+
I don’t think it is hyperbole to say that HTML5 will change the way that you think about web development. I welcome many of the changes as they make development easier, and the user experience richer. With any change, though, there is certain to be a bit of trepidation and controversy. One addition that certainly is not without its controversy is the Microdata specification, but I believe the benefits of this very simple specification are going to change how you look at your mark-up in the very near future.
html  html5  markup  metadata  microdata  semanticweb  seo  rdfa  data 
august 2010 by michaelfox
The Power of HTML 5 and CSS 3 • Perishable Press
Web designers can do some pretty cool stuff with HTML 4 and CSS 2.1. We can structure our documents logically and create information-rich sites without relying on archaic, table-based layouts. We can style our web pages with beauty and detail without resorting to inline <font> and <br> tags. Indeed, our current design methods have taken us far beyond the hellish era of browser wars, proprietary protocols, and those hideous flashing, scrolling, and blinking web pages.

As far as we’ve come using HTML 4 and CSS 2.1, however, we can do better. We can refine the structure of our documents and increase their semantic precision. We can sharpen the presentation of our stylesheets and advance their stylistic flexibility. As we continue to push the boundaries of existing languages, HTML 5 and CSS 3 are quickly gaining popularity, revealing their collective power with some exciting new design possibilities.
html5  css3  html  css  webdesign  webdev  semantic  markup 
april 2010 by michaelfox
GitHub SphereCat1 TagReplacer - Raw - jquery.tagreplacer.js
* Checks your document for HTML5 tags like <section>, <header>, etc, and replaces them with divs. * Designed for use with IE detection, so you can still use awesome HTML5 tags.

TagReplacer.js - A simple jQuery function to find HTML elements of a specified type and replace them with something else.

Usage:
All you need to do is call $.replaceTags() with an associative array as the argument.
Example: $("body").replaceTags({tagToReplace:"replaceWith", p:"div", b:"span"});
jquery  html  markup 
april 2010 by michaelfox

Copy this bookmark:



description:


tags: