diff --git a/README.md b/README.md index 6724eb8d..72da6acd 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ -# h5ai v0.10   ·   a beautified Apache index +# h5ai v0.10.1   ·   a beautified Apache index h5ai aims to make browsing files on a Apache HTTP server more comfortable. See the [live demo](http://larsjung.de/h5ai/sample). @@ -20,6 +20,12 @@ please respect their rights. ## Changelog +### v0.10.1 +*2011-07-24* + +* fixed problems with ' in links + + ### v0.10 *2011-07-24* diff --git a/build.properties b/build.properties index 3723d87e..8235b751 100644 --- a/build.properties +++ b/build.properties @@ -3,7 +3,7 @@ custom = true # project project.name = h5ai -project.version = 0.10 +project.version = 0.10.1 # src diff --git a/src/h5ai/js/inc/path.js b/src/h5ai/js/inc/path.js index febb7594..2620906d 100644 --- a/src/h5ai/js/inc/path.js +++ b/src/h5ai/js/inc/path.js @@ -227,7 +227,8 @@ var Path = function ( pathCache, folder, tableRow ) { try { $html.addClass( this.isFolder ? "folder" : "file" ); - var $a = $( ">" + this.label + "" ); + var $a = $( ">" + this.label + "" ); + $a.attr( "href", this.absHref ); $a.click( $.proxy( function() { this.onClick( "crumb" ); }, this ) ); $a.hover( $.proxy( function() { this.onHoverIn( "crumb" ); }, this ), $.proxy( function() { this.onHoverOut( "crumb" ); }, this ) ); $html.append( $a ); @@ -267,7 +268,8 @@ var Path = function ( pathCache, folder, tableRow ) { try { $html.addClass( this.isFolder ? "folder" : "file" ); - var $a = $( "" ).appendTo( $html ); + var $a = $( "" ).appendTo( $html ); + $a.attr( "href", this.absHref ); $a.click( $.proxy( function() { this.onClick( "extended" ); }, this ) ); $a.hover( $.proxy( function() { this.onHoverIn( "extended" ); }, this ), $.proxy( function() { this.onHoverOut( "extended" ); }, this ) ); @@ -314,10 +316,11 @@ var Path = function ( pathCache, folder, tableRow ) { try { $html.addClass( this.isFolder ? "folder" : "file" ); - var $a = $( "" ) + var $a = $( "" ) .appendTo( $html ) .append( $( "" ) ) .append( $( "" + this.label + "" ) ); + $a.attr( "href", this.absHref ); $a.click( $.proxy( function() { this.onClick( "tree" ); }, this ) ); $a.hover( $.proxy( function() { this.onHoverIn( "tree" ); }, this ), $.proxy( function() { this.onHoverOut( "tree" ); }, this ) ); diff --git a/target/dot.htaccess b/target/dot.htaccess index caf25642..ec13f286 100644 --- a/target/dot.htaccess +++ b/target/dot.htaccess @@ -1,5 +1,5 @@ ################################ -# h5ai 0.10 +# h5ai 0.10.1 # customized .htaccess ################################ @@ -62,7 +62,7 @@ IndexOrderDefault Ascending Name - IndexOptions Type=text/html;h5ai=0.10 + IndexOptions Type=text/html;h5ai=0.10.1 IndexOptions Charset=UTF-8 IndexOptions FancyIndexing IndexOptions HTMLTable diff --git a/target/h5ai/footer.html b/target/h5ai/footer.html index c1b17a54..90a6e199 100644 --- a/target/h5ai/footer.html +++ b/target/h5ai/footer.html @@ -11,7 +11,7 @@ html5-storage html5-css3 - h5ai 0.10 + h5ai 0.10.1 using Faenza icons diff --git a/target/h5ai/header.html b/target/h5ai/header.html index d0770b70..767b387d 100644 --- a/target/h5ai/header.html +++ b/target/h5ai/header.html @@ -3,7 +3,7 @@ Directory index · styled with h5ai - + diff --git a/target/h5ai/js/main.js b/target/h5ai/js/main.js index 89287a14..ea10a598 100644 --- a/target/h5ai/js/main.js +++ b/target/h5ai/js/main.js @@ -1 +1 @@ -(function($){(function($){$.toJSON=function(o){if(typeof(JSON)=="object"&&JSON.stringify){return JSON.stringify(o)}var type=typeof(o);if(o===null){return"null"}if(type=="undefined"){return undefined}if(type=="number"||type=="boolean"){return o+""}if(type=="string"){return $.quoteString(o)}if(type=="object"){if(typeof o.toJSON=="function"){return $.toJSON(o.toJSON())}if(o.constructor===Date){var month=o.getUTCMonth()+1;if(month<10){month="0"+month}var day=o.getUTCDate();if(day<10){day="0"+day}var year=o.getUTCFullYear();var hours=o.getUTCHours();if(hours<10){hours="0"+hours}var minutes=o.getUTCMinutes();if(minutes<10){minutes="0"+minutes}var seconds=o.getUTCSeconds();if(seconds<10){seconds="0"+seconds}var milli=o.getUTCMilliseconds();if(milli<100){milli="0"+milli}if(milli<10){milli="0"+milli}return'"'+year+"-"+month+"-"+day+"T"+hours+":"+minutes+":"+seconds+"."+milli+'Z"'}if(o.constructor===Array){var ret=[];for(var i=0;i a").addClass("hover")}}}};this.onHoverOut=function(){if(h5ai.config.linkHoverStates){for(ref in this.html){$ref=this.html[ref];if($ref!==undefined){$ref.find("> a").removeClass("hover")}}}};this.updateHtml=function(){this.updateCrumbHtml();this.updateExtendedHtml();this.updateTreeHtml()};this.updateCrumbHtml=function(){var $html=$("
  • ").data("path",this);try{$html.addClass(this.isFolder?"folder":"file");var $a=$(">"+this.label+"");$a.click($.proxy(function(){this.onClick("crumb")},this));$a.hover($.proxy(function(){this.onHoverIn("crumb")},this),$.proxy(function(){this.onHoverOut("crumb")},this));$html.append($a);if(this.isDomain){$html.addClass("domain");$a.find("img").attr("src","/h5ai/images/home.png")}if(this.isCurrentFolder){$html.addClass("current")}if(!isNaN(this.status)){if(this.status===200){$("not listable").appendTo($a)}else{$("("+this.status+")").appendTo($a)}}}catch(err){$("failed").appendTo($html)}if(this.html.$crumb!==undefined){this.html.$crumb.replaceWith($html)}this.html.$crumb=$html;return $html};this.updateExtendedHtml=function(){var $html=$("
  • ").data("path",this);try{$html.addClass(this.isFolder?"folder":"file");var $a=$("").appendTo($html);$a.click($.proxy(function(){this.onClick("extended")},this));$a.hover($.proxy(function(){this.onHoverIn("extended")},this),$.proxy(function(){this.onHoverOut("extended")},this));$(""+this.alt+"").appendTo($a);$(""+this.alt+"").appendTo($a);var $label=$(""+this.label+"").appendTo($a);$(""+this.date+"").appendTo($a);$(""+this.size+"").appendTo($a);if(this.isParentFolder){if(!h5ai.config.setParentFolderLabels){$label.addClass("l10n-parentDirectory")}$html.addClass("parentfolder")}if(!isNaN(this.status)){if(this.status===200){$html.addClass("page");$a.find(".icon.small img").attr("src","/h5ai/icons/16x16/folder-page.png");$a.find(".icon.big img").attr("src","/h5ai/icons/48x48/folder-page.png")}else{$html.addClass("error");$label.append($(" "+this.status+" "))}}}catch(err){$("failed").appendTo($html)}if(this.html.$extended!==undefined){this.html.$extended.replaceWith($html)}this.html.$extended=$html;return $html};this.updateTreeHtml=function(){var $html=$("
    ").data("path",this);var $blank=$("").appendTo($html);try{$html.addClass(this.isFolder?"folder":"file");var $a=$("").appendTo($html).append($("")).append($(""+this.label+""));$a.click($.proxy(function(){this.onClick("tree")},this));$a.hover($.proxy(function(){this.onHoverIn("tree")},this),$.proxy(function(){this.onHoverOut("tree")},this));if(this.isFolder){if(this.status===undefined||!this.isEmpty()){var $indicator=$("");if(this.status===undefined){$indicator.addClass("unknown")}else{if(this.treeOpen){$indicator.addClass("open")}}$indicator.click($.proxy(function(event){if($indicator.hasClass("unknown")){tree.fetchStatusAndContent(this.absHref,false,$.proxy(function(status,content){this.status=status;this.content=content;this.treeOpen=true;this.updateTreeHtml(function(){$("#tree").get(0).updateScrollbar()})},this))}else{if($indicator.hasClass("open")){this.treeOpen=false;$indicator.removeClass("open");$html.find("> ul.content").slideUp(function(){$("#tree").get(0).updateScrollbar()})}else{this.treeOpen=true;$indicator.addClass("open");$html.find("> ul.content").slideDown(function(){$("#tree").get(0).updateScrollbar()})}}},this));$blank.replaceWith($indicator)}if(this.isDomain){$html.addClass("domain");$a.find(".icon img").attr("src","/h5ai/icons/16x16/folder-home.png")}if(this.isCurrentFolder){$html.addClass("current");$a.find(".icon img").attr("src","/h5ai/icons/16x16/folder-open.png")}if(!this.isEmpty()){var $ul=$("