예제 #1
0
        $quick['ID'] = $post_ID;
        wp_update_post($quick);
    }
    return $post_ID;
}
// For submitted posts.
if (isset($_REQUEST['action']) && 'post' == $_REQUEST['action']) {
    check_admin_referer('press-this');
    $post_ID = press_it();
    $posted = $post_ID;
} else {
    $post_ID = 0;
}
// Set Variables
$title = isset($_GET['t']) ? esc_html(aposfix(stripslashes($_GET['t']))) : '';
$selection = isset($_GET['s']) ? trim(aposfix(stripslashes($_GET['s']))) : '';
if (!empty($selection)) {
    $selection = preg_replace('/(\\r?\\n|\\r)/', '</p><p>', $selection);
    $selection = '<p>' . str_replace('<p></p>', '', $selection) . '</p>';
}
$url = isset($_GET['u']) ? esc_url($_GET['u']) : '';
$image = isset($_GET['i']) ? $_GET['i'] : '';
if (!empty($_REQUEST['ajax'])) {
    switch ($_REQUEST['ajax']) {
        case 'video':
            ?>
			<script type="text/javascript" charset="utf-8">
			/* <![CDATA[ */
				jQuery('.select').click(function() {
					append_editor(jQuery('#embed-code').val());
					jQuery('#extra-fields').hide();
예제 #2
0
        $quick['ID'] = $post_ID;
        wp_update_post($quick);
    }
    return $post_ID;
}
// For submitted posts.
if (isset($_REQUEST['action']) && 'post' == $_REQUEST['action']) {
    check_admin_referer('press-this');
    $post_ID = press_it();
    $posted = $post_ID;
} else {
    $post_ID = 0;
}
// Set Variables
$title = isset($_GET['t']) ? trim(strip_tags(aposfix(stripslashes($_GET['t'])))) : '';
$selection = isset($_GET['s']) ? trim(htmlspecialchars(html_entity_decode(aposfix(stripslashes($_GET['s']))))) : '';
if (!empty($selection)) {
    $selection = preg_replace('/(\\r?\\n|\\r)/', '</p><p>', $selection);
    $selection = '<p>' . str_replace('<p></p>', '', $selection) . '</p>';
}
$url = isset($_GET['u']) ? esc_url($_GET['u']) : '';
$image = isset($_GET['i']) ? $_GET['i'] : '';
if (!empty($_REQUEST['ajax'])) {
    switch ($_REQUEST['ajax']) {
        case 'video':
            ?>
			<script type="text/javascript" charset="utf-8">
			/* <![CDATA[ */
				jQuery('.select').click(function() {
					append_editor(jQuery('#embed-code').val());
					jQuery('#extra-fields').hide();
		<p><?php
		do_action('in_admin_footer', '');
		$upgrade = apply_filters( 'update_footer', '' );
		echo __('Thank you for creating with <a href="http://wordpress.org/">WordPress</a>');
		?></p>
		</div>
		<?php do_action('admin_footer', ''); ?>
	</body>
	</html>
	<?php die;
}

// Ajax Requests
$title = wp_specialchars(aposfix(stripslashes($_GET['t'])));

$selection = trim( aposfix( stripslashes($_GET['s']) ) );
if ( ! empty($selection) ) {
	$selection = preg_replace('/(\r?\n|\r)/', '</p><p>', $selection);
	$selection = '<p>'.str_replace('<p></p>', '', $selection).'</p>';
}

$url = clean_url($_GET['u']);
$image = $_GET['i'];

if($_REQUEST['ajax'] == 'thickbox') { ?>
	<script type="text/javascript" charset="utf-8">
		jQuery('.cancel').click(function() {
			tb_remove();
		});

		jQuery('.select').click(function() {