It looks like you're offline.
Open Library logo
additional options menu

view template for /type/rawtext

This doc was last edited anonymously March 16, 2009.

plugin upstream
Templates in the website are disabled now. Editing them will not have any effect on the live website.
   1
   2
   3
   4
   5
   6
   7
   8
   9
  10
  11
  12
  13
  14
  15
  16
  17
  18
  19
  20
$def with (page)

$var title: $page.title

$ format = query_param('format')
$if format == 'raw':
    $var content_type: $page.content_type
    $var rawtext: $:page.body
$else:
    <div id="header" style="padding-left: 24px;">
        <div id="title">$page.title</div>
        <div class="statement" style="padding-left: 6px;">
            <a href="$page.key?format=raw">View as rawtext</a>
            $if page.key.endswith(".css"):
                | <a href="#" onclick="document.location.href='http://jigsaw.w3.org/css-validator/validator?uri=' + escape(document.location.href.replace('#', '') + '?format=raw');">Validate CSS</a>
        </div>
    </div>
    <hr />

$:macros.DisplayCode(page.body)