#!/usr/bin/env python
#-*-mode: python -*- -*- coding: utf-8 -*-

import urllib2
import sys

stream = urllib2.urlopen(sys.argv[1])
data = stream.read()
stream.close()

(junk, divider, body) = data.partition('<!-- start content -->')
(body, divider, junk) = body.partition('<!-- end content -->')
(body, divider, junk) = body.partition('''<!-- 
NewPP limit report
Preprocessor node count:''')



print """<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
<head>
  <meta name="generator" content=
  "HTML Tidy for Linux/x86 (vers 7 December 2008), see www.w3.org" />

  <title>Mission Possible: Deploying Government Linked Data</title>
  <meta name="copyright" content=
  "Copyright &copy; 2009 W3C (MIT, ERCIM, Keio)" />
  <link rel="stylesheet" type="text/css" media=
  "screen, projection, print" href=
  "../../../Talks/Tools/Slidy/slidy.css" />
  <script src="../../../Talks/Tools/Slidy/slidy.js"
  charset="utf-8" type="text/javascript">

</script>
  <link rel="stylesheet" type="text/css" media=
  "screen, projection, print" href=
  "../../../Talks/Tools/Slidy/w3c-blue2.css" />
  <style type="text/css">
/*<![CDATA[*/

    <!-- your custom style rules --> 

    div.nothing {
       // first entry doesnt work
    }

    div.hbox {
       width:85%;  margin-top: 0;
       margin-left:auto; margin-right:auto;
       height: 75%;
       border:1px solid silver;
       background:#F0F0F0;
       overflow:auto;
       text-align:left;
       clear:both;
    }

    .attn {
        text-weight: bold;
        color: red;
    }
    
    table {
       margin: 0.3em;
       border-collapse: collapse;
       background: #FFF;
    }

    th,td {
       padding: 4px 1em;
       border: 1px black solid;
    }
    th {
       background: #ccc;
    }
    td {
       background: #eee;
    }


    pre { border-width: thin; }

    td pre { margin: 0;  padding 0; }


    div.slide h1 {
    }

    .tight li {
       margin-top: 0;
       margin-bottom: 0;
    }
    .tight ul {
       margin-top: 0;
       margin-bottom: 0;
    }
    .tight p {
       margin-top: 0.25em;
       margin-bottom: 0.25em;
    }


  /*]]>*/
  </style>
</head>

<body>
  <div class="background"> 
    <img id="head-icon" alt="graphic with four colored squares"
	 src="../../../Talks/Tools/Slidy/icon-blue.png" /> 
    <object id="head-logo" title="W3C logo" type="image/svg+xml"
	    data="../../../Talks/Tools/Slidy/w3c-logo-white.svg"><img
	    src="../../../Talks/Tools/Slidy/w3c-logo-white.gif" 
	    alt="W3C logo" id="head-logo-fallback" /></object>
  </div> 


  <div class="slide cover title">

 <img src="../../../Talks/Tools/Slidy/keys2.jpg" 
  alt="Cover page images (keys)" class="cover" /> 
 <br clear="all" />    


    <h1>Mission Possible: Deploying Government Linked Data</h1>

    <p>
    
    <a href="http://www.w3.org/People/Sandro/">Sandro Hawke</a>
    <a href="mailto:sandro@w3.org">(sandro@w3.org)</a>, W3C /
    MIT, <a href="http://twitter.com/sandhawke">@sandhawke</a><br />

    <a href="@@@">John L. Sheridan</a>
    <a href="mailto:@@">(@@)</a>, <a href="http://twitter.com/johnlsheridan">@johnlsheridan<br />

    <a href="@@@">@@@Event</a>, @@@date<br />

    <a href=
    "http://www.w3.org/2010/Talks/0525-linked-data">http://www.w3.org/2010/Talks/0525-linked-data</a> (<a href="http://www.w3.org/egov/wiki/GLD_Tutorial">wiki</a>)
</p>

  </div>

 
"""

started=False
for line in body.split("\n"):
    if started:
        print line
    else:
        if "mw-headline" in line:
            started=True
            print line

print "</body></html>"



