This commit is contained in:
Colin Mitchell 2013-02-15 20:11:44 -05:00
parent fa15fa278f
commit 3d03cff797
5 changed files with 22 additions and 6 deletions

View File

@ -11,3 +11,7 @@ RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^ index.php [QSA,L]
<FilesMatch "\.(jpg|jpeg|png|gif|swf)$">
Header set Cache-Control "max-age=604800, public"
</FilesMatch>

View File

@ -157,6 +157,17 @@ GopherParser.prototype.entryToLink = function(e) {
return (str + '').replace(/([^>\r\n]?)(\r\n|\n\r|\r|\n)/g, '$1' + breakTag + '$2');
}
/* function urlify(text) {
var urlRegex = /(https?:\/\/[^\s]+)/g;
return text.replace(urlRegex, function(url) {
return '<a href="' + url + '">' + url + '</a>';
})
// or alternatively
// return text.replace(urlRegex, '<a href="$1">$1</a>')
}
*/
/**
* parse some gophertext and render some pretty HTML from it.
*
@ -185,6 +196,9 @@ GopherParser.prototype.entryToLink = function(e) {
else {
$(this).html(nl2br(data));
}
// $(this).html(urlify(data));
}
else {
entries = parser.parseGopher(data);

View File

@ -193,4 +193,4 @@ $(document).ready(function() {
if ( window.location.pathname != "/" && $("#intro").hasClass("hide") ) {
loadGopherUri(unescape(window.location.pathname));
}
});
});

View File

@ -5,7 +5,7 @@
died off in the late 1990s, partially because of some poor decisions
by the University of Minnesota (which owned the licensing rights,
and <a href="http://www.nic.funet.fi/pub/vms/networking/gopher/gopher-software-licensing-policy.ancient">decided
to charge for use</a>), and also because HTTP and HTML was
to charge for use</a>), and of course also because HTTP and HTML was
undoubtedly a better system for what became the World Wide Web.
</p>
<p>

View File

@ -83,11 +83,9 @@
<script src="//ajax.googleapis.com/ajax/libs/jquery/1.7.2/jquery.min.js"></script>
<script src="/assets/js/jquery.history.js"></script>
<script src="/assets/js/compressed.js"></script>
<!--
<script src="/assets/js/jquery.colorbox-min.js"></script>
<!-- <script src="/assets/js/compressed.js"></script>-->
<script src="/assets/js/jquery.colorbox.js"></script>
<script src="/assets/js/gopher.js"></script>
<script src="/assets/js/site.js"></script>
-->
</body>
</html>