Make WordPress Core


Ignore:
Timestamp:
08/09/2008 05:36:14 AM (17 years ago)
Author:
ryan
Message:

Trailing whitespace cleanup

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/press-this.php

    r8551 r8600  
    3535
    3636            foreach( (array) $_REQUEST['photo_src'] as $key => $image) {
    37                
     37
    3838                // see if files exist in content - we don't want to upload non-used selected files.
    3939                if( strpos($_REQUEST['content'], $image) !== false ) {
    4040                    $upload = media_sideload_image($image, $post_ID, $_REQUEST['photo_description'][$key]);
    41                      
     41
    4242                    // Replace the POSTED content <img> with correct uploaded ones.
    4343                    // escape quote for matching
     
    5050
    5151        case "video":
    52             if($_REQUEST['embed_code']) 
     52            if($_REQUEST['embed_code'])
    5353                $content .= $_REQUEST['embed_code']."\n\n";
    5454            $content .= $_REQUEST['content'];
     
    7474
    7575// For submitted posts.
    76 if ( 'post' == $_REQUEST['action'] ) { 
     76if ( 'post' == $_REQUEST['action'] ) {
    7777    check_admin_referer('press-this'); $post_ID = press_it(); ?>
    7878    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
     
    139139
    140140    <p id="options"><a href="#" class="select button"><?php _e('Insert Image'); ?></a> <a href="#" class="cancel button"><?php _e('Cancel'); ?></a></p>
    141 <?php die; 
     141<?php die;
    142142}
    143143
     
    164164
    165165    <p id="options"><a href="#" class="select"><?php _e('Insert Image'); ?></a> | <a href="#" class="cancel"><?php _e('Cancel'); ?></a></p>
    166 <?php die; 
     166<?php die;
    167167}
    168168
     
    177177if($_REQUEST['ajax'] == 'photo_images') {
    178178    function get_images_from_uri($uri) {
    179         if( preg_match('/\.(jpg|jpe|jpeg|png|gif)/', $uri) && !strpos($uri,'blogger.com') ) 
     179        if( preg_match('/\.(jpg|jpe|jpeg|png|gif)/', $uri) && !strpos($uri,'blogger.com') )
    180180            return "'".$uri."'";
    181181
     
    187187        $pattern = '/<img ([^>]*)src=(\"|\')([^<>]+?\.(png|jpeg|jpg|jpe|gif))[^<>\'\"]*(\2)([^>\/]*)\/*>/is';
    188188        preg_match_all($pattern, $content, $matches);
    189        
     189
    190190        if ( empty($matches[1]) ) return '';
    191191
     
    199199                else
    200200                    $src = 'http://'.str_replace('//','/', $host['host'].'/'.dirname($host['path']).'/'.$src);
    201            
     201
    202202            $sources[] = clean_url($src);
    203203        }
    204204        return "'" . implode("','", $sources) . "'";
    205     } 
     205    }
    206206
    207207    $url = urldecode($url);
    208208    $url = str_replace(' ', '%20', $url);
    209     echo 'new Array('.get_images_from_uri($url).')'; 
     209    echo 'new Array('.get_images_from_uri($url).')';
    210210die;
    211211}
     
    227227
    228228    for (i = 0; i < my_src.length; i++) {
    229         img = new Image(); 
    230         img.src = my_src[i]; 
    231         img_attr = 'id="img' + i + '"'; 
     229        img = new Image();
     230        img.src = my_src[i];
     231        img_attr = 'id="img' + i + '"';
    232232        skip = false;
    233233        if (img.width && img.height) {
    234             if (img.width * img.height < 2500) 
     234            if (img.width * img.height < 2500)
    235235                skip = true;
    236236            aspect = img.width / img.height;
     
    304304?>
    305305    <script type="text/javascript">
    306     <?php if ( user_can_richedit() ) { 
     306    <?php if ( user_can_richedit() ) {
    307307        $language = ( '' == get_locale() ) ? 'en' : strtolower( substr(get_locale(), 0, 2) );
    308308        // Add TinyMCE languages
     
    360360    });
    361361    jQuery('#newtag').blur(function() {
    362         if ( this.value == '' ) 
     362        if ( this.value == '' )
    363363            jQuery(this).val( postL10n.addTag ).addClass( 'form-input-tip' );
    364364    });
     
    412412                jQuery('body').addClass('video_split');
    413413                jQuery('#extra_fields').load('<?php echo clean_url($_SERVER['PHP_SELF']); ?>', { ajax: 'video', s: '<?php echo attribute_escape($selection); ?>'}, function() {
    414                     <?php 
     414                    <?php
    415415                    $content = '';
    416416                    if ( preg_match("/youtube\.com\/watch/i", $url) ) {
     
    461461
    462462    jQuery(document).ready(function() {
    463         jQuery('#menu li').click(function (){ 
     463        jQuery('#menu li').click(function (){
    464464            tab_name = this.id.split('_');
    465465            tab_name = tab_name[0];
     
    519519                    </ul>
    520520                </div>
    521                
     521
    522522                <h2><?php _e('Tags') ?></h2>
    523523                <p id="jaxtag"><label class="hidden" for="newtag"><?php _e('Tags'); ?></label><input type="text" name="tags_input" class="tags-input" id="tags-input" size="40" tabindex="3" value="<?php echo get_tags_to_edit( $post->ID ); ?>" /></p>
     
    525525            </div>
    526526
    527             <p class="submit">         
     527            <p class="submit">
    528528                <input type="submit" name="draft" value="<?php _e('Save') ?>" onclick="document.getElementById('photo_saving').style.display = '';"/>
    529529                <input type="submit" name="publish" value="<?php _e('Publish') ?>" onclick="document.getElementById('photo_saving').style.display = '';"/>
Note: See TracChangeset for help on using the changeset viewer.