1
0
mirror of https://github.com/lrsjng/h5ai.git synced 2025-08-28 08:10:17 +02:00

Fixed problems with ' in links

This commit is contained in:
Lars Jung
2011-07-24 18:05:44 +02:00
parent 5708b2e38e
commit 89fd74c4ab
8 changed files with 20 additions and 11 deletions

View File

@@ -227,7 +227,8 @@ var Path = function ( pathCache, folder, tableRow ) {
try {
$html.addClass( this.isFolder ? "folder" : "file" );
var $a = $( "<a href='" + this.absHref + "'><img src='/h5ai/images/crumb.png' alt='>' />" + this.label + "</a>" );
var $a = $( "<a><img src='/h5ai/images/crumb.png' alt='>' />" + this.label + "</a>" );
$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 = $( "<a href='" + this.absHref + "' />" ).appendTo( $html );
var $a = $( "<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 = $( "<a href='" + this.absHref + "' />" )
var $a = $( "<a />" )
.appendTo( $html )
.append( $( "<span class='icon'><img src='" + this.icon16 + "' /></span>" ) )
.append( $( "<span class='label'>" + this.label + "</span>" ) );
$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 ) );