Make WordPress Core

Changeset 4748


Ignore:
Timestamp:
01/16/2007 06:10:54 PM (18 years ago)
Author:
ryan
Message:

Send to Editor fixes from mdawaffe. fixes #3594

Location:
trunk
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/upload-js.php

    r4746 r4748  
    5757                this.currentImage.height = false;
    5858            }
    59             this.currentImage.isImage = ( 0 == id ? '' : $('attachment-is-image-' + id).value );
     59            this.currentImage.isImage = ( 0 == id ? 0 : $('attachment-is-image-' + id).value );
    6060            this.currentImage.ID = id;
    6161        },
     
    7575            }
    7676            h += "<div id='file-title'>"
    77             if ( !this.currentImage.isImage )
     77            if ( 0 == this.currentImage.isImage )
    7878                h += "<h2><a href='" + this.currentImage.srcBase + this.currentImage.src + "' onclick='return false;' title='<?php echo attribute_escape(__('Direct link to file')); ?>'>" + this.currentImage.title + "</a></h2>";
    7979            else
     
    8484            h += '</div>'
    8585            h += "<div id='upload-file-view' class='alignleft'>";
    86             if ( this.currentImage.isImage ) {
     86            if ( 1 == this.currentImage.isImage ) {
    8787                h += "<a href='" + this.currentImage.srcBase + this.currentImage.src + "' onclick='return false;' title='<?php echo attribute_escape(__('Direct link to file')); ?>'>";
    8888                h += "<img src='" + ( this.currentImage.thumb ? this.currentImage.thumb : this.currentImage.src ) + "' alt='" + this.currentImage.title + "' width='" + this.currentImage.width + "' height='" + this.currentImage.height + "' />";
     
    153153            }
    154154            h += "<div id='file-title'>"
    155             if ( !this.currentImage.isImage )
     155            if ( 0 == this.currentImage.isImage )
    156156                h += "<h2><a href='" + this.currentImage.srcBase + this.currentImage.src + "' onclick='return false;' title='<?php echo attribute_escape(__('Direct link to file')); ?>'>" + this.currentImage.title + "</a></h2>";
    157157            else
     
    162162            h += '</div>'
    163163            h += "<div id='upload-file-view' class='alignleft'>";
    164             if ( this.currentImage.isImage ) {
     164            if ( 1 == this.currentImage.isImage ) {
    165165                h += "<a href='" + this.currentImage.srcBase + this.currentImage.src + "' onclick='return false;' title='<?php echo wp_specialchars(__('Direct link to file')); ?>'>";
    166166                h += "<img src='" + ( this.currentImage.thumb ? this.currentImage.thumb : this.currentImage.src ) + "' alt='" + this.currentImage.title + "' width='" + this.currentImage.width + "' height='" + this.currentImage.height + "' />";
     
    231231            if ( displayEl )
    232232                display = displayEl.value;
    233             else if ( this.currentImage.isImage )
     233            else if ( 1 == this.currentImage.isImage )
    234234                display = 'full';
    235235
  • trunk/wp-includes/post-template.php

    r4723 r4748  
    369369    }
    370370
    371     if ( !isset($src) )
     371    if ( !isset($src) || !$src )
    372372        return false;
     373
    373374    return array($src, $src_file);
    374375}
  • trunk/wp-includes/script-loader.php

    r4701 r4748  
    3939            $this->add( 'admin-users', '/wp-admin/users.js', array('listman'), '4583' );
    4040            $this->add( 'xfn', '/wp-admin/xfn.js', false, '3517' );
    41             $this->add( 'upload', '/wp-admin/upload-js.php', array('prototype'), '20061223' );
     41            $this->add( 'upload', '/wp-admin/upload-js.php', array('prototype'), '20070116' );
    4242        }
    4343    }
Note: See TracChangeset for help on using the changeset viewer.