Make WordPress Core


Ignore:
Timestamp:
05/22/2008 03:47:37 PM (17 years ago)
Author:
ryan
Message:

Press This fixes from noel. see #6998

File:
1 edited

Legend:

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

    r7979 r7983  
    2323            $content = $_REQUEST['content'];
    2424            if ($_REQUEST['content2'])
    25                 $content .= '<p>' . $_REQUEST['content2'];
     25                $content .= $_REQUEST['content2'];
    2626            break;
    2727
     
    2929            $content = '<blockquote>' . $_REQUEST['content'];
    3030            if ($_REQUEST['content2']) {
    31                 $content .= '</blockquote>';
    32                 $content = $content . '<p>' . $_REQUEST['content2'].'</p>';
     31                $content .= '</blockquote>
     32                ';
     33                $content = $content . $_REQUEST['content2'];
    3334            }
    3435            break;
     
    3637        case 'photo':
    3738            if ($_REQUEST['photo_link'])
    38                 $content = '<p><a href="' . $_REQUEST['photo_link'] . '" target="_new">';
     39                $content = '<a href="' . $_REQUEST['photo_link'] . '" target="_new">';
    3940
    4041            $content .= '<img src="' . $_REQUEST['photo_src'] . '" alt=""/>';
    4142
    4243            if ($_REQUEST['photo_link'])
    43                 $content .= '</a></p>';
     44                $content .= '</a>
     45                ';
    4446
    4547            if ($_REQUEST['content'])
    46                 $content = $content . $_REQUEST['content'];
     48                $content = $content . "\n".$_REQUEST['content'];
    4749
    4850            break;
     
    5153            $content = '<object width="425" height="350"><param name="movie" value="http://www.youtube.com/v/' . $video_id . '"></param><param name="wmode" value="transparent"></param><embed src="http://www.youtube.com/v/' . $video_id . '" type="application/x-shockwave-flash" wmode="transparent" width="425" height="350"></embed></object>';
    5254            if ($_REQUEST['content2'])
    53                 $content .= '<p>' . $_REQUEST['content2'] . '</p>';
     55                $content .= "\n" . $_REQUEST['content2'];
    5456            break;             
    5557    }
     
    153155                accessibility_focus : false,
    154156                tab_focus : ":next",
    155                 plugins : "safari,inlinepopups"
     157                plugins : "safari,inlinepopups",
     158                entity_encoding : "raw"
    156159            });
    157160    <?php } ?>
     
    162165
    163166        // add the quickadd form
    164         jQuery('#jaxtag').prepend('<span id="ajaxtag"><input type="text" name="newtag" id="newtag" class="form-input-tip" size="16" autocomplete="off" value="'+postL10n.addTag+'" /><input type="button" class="button" id="tagadd" value="' + postL10n.add + '" tabindex="3" /><input type="hidden"/><input type="hidden"/><span class="howto">'+postL10n.separate+'</span></span>');
     167        jQuery('#jaxtag').prepend('<span id="ajaxtag"><input type="text" name="newtag" id="newtag" class="form-input-tip" size="16" autocomplete="off" value="'+postL10n.addTag+'" /><input type="submit" class="button" id="tagadd" value="' + postL10n.add + '" tabindex="3" onclick="return false;" /><input type="hidden"/><input type="hidden"/><span class="howto">'+postL10n.separate+'</span></span>');
    165168       
    166169        jQuery('#tagadd').click( tag_flush_to_text );
     
    192195    <meta http-equiv="Content-Type" content="<?php bloginfo('html_type'); ?>; charset=<?php echo get_option('blog_charset'); ?>" />
    193196    <title><?php _e('Press This') ?></title>
     197
    194198    <script type="text/javascript" src="../wp-includes/js/tinymce/tiny_mce.js"></script>
    195199<?php
     
    217221
    218222    </script>
     223   
     224
    219225</head>
    220226<body>
     
    244250                }
    245251                last = img;
     252               
     253                /*jQuery('.photolist').append('<h2><?php _e("Photo URL") ?></h2>' +
     254                '<div class="titlewrap">' +
     255                '<a href="#" class="remove">remove <input name="photo_src" id="photo_src[]" value ="'+ img.src +'" class="text" onkeydown="pick(0);"/></a>' +
     256                '</div>');*/
    246257                return false;
    247258            }
    248            
     259
     260            jQuery('.remove').click(function() {
     261                jQuery(this).remove;
     262               
     263            });
    249264            jQuery(document).ready(function() {
    250265                var img, img_tag, aspect, w, h, skip, i, strtoappend = "";
     
    301316                    </div>
    302317                   
     318                    <div class="photolist"></div>
     319                   
    303320                    <h2><?php _e('Link Photo to following URL') ?></h2><?php _e('(leave blank to leave the photo unlinked)') ?>
    304321                    <div class="titlewrap">
     
    316333                    <div class="editor-container">
    317334                        <textarea name="content" id="photo_post_two" style="" class="mceEditor"><?php echo $selection;?>
    318                         &lt;a href="<?php echo attribute_escape($url);?>"&gt;<?php echo $title;?>&lt;/a&gt;</textarea>
     335                        &lt;a href="<?php echo attribute_escape($url);?>"&gt;<?php echo $title;?>&lt;/a&gt; </textarea>
    319336                    </div>
    320337
     
    344361                    <h2><?php _e('Post') ?></h2>
    345362                    <div class="editor-container">
    346                         <textarea name="content" id="regular_post_two" style="height:170px;width:100%;" class="mceEditor"><?php echo $selection;?>&lt;a href="<?php echo $url;?>"&gt;<?php echo $title;?>&lt;/a&gt;</textarea>
     363                        <textarea name="content" id="regular_post_two" style="height:170px;width:100%;" class="mceEditor"><?php echo $selection;?><a href="<?php echo $url;?>"><?php echo $title;?></a></textarea>
    347364                    </div>       
    348365
Note: See TracChangeset for help on using the changeset viewer.