Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Using jQuery, Code Prettify, and CSS3 :target, we can make a button that pops up a nice looking view of the current pages source code.
branch: master
Failed to load latest commit information.
css
images Added files
prettify Added files
index.html renamed .php to .html, Removed GA and added latest jQuery
readme.markdown removed .md replaced with .markdown because that's how cool

readme.markdown

View-Source-Button (Article / Demo)

The idea that first came to mind was to use CSS3's :target pseudo class. We talked about these a while back while exporting CSS3 tabs. The idea is to have a link that links to the #source-code hash tag. That puts #source-code at the end of the URL, and allows the :target selector to match and apply styling.

Something went wrong with that request. Please try again.