Make WordPress Core

Changeset 6788


Ignore:
Timestamp:
02/11/2008 05:40:16 PM (16 years ago)
Author:
ryan
Message:

Fix edit slug ajax nonce. props nbachiyski. see #5816

Location:
trunk/wp-admin
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/admin-ajax.php

    r6761 r6788  
    526526break;
    527527case 'sample-permalink':
    528     check_ajax_referer( $action );
     528    check_ajax_referer( 'samplepermalink', 'samplepermalinknonce' );
    529529    $post_id = isset($_POST['post_id'])? intval($_POST['post_id']) : 0;
    530530    die(get_sample_permalink_html($post_id, $_POST['new_slug']));
  • trunk/wp-admin/edit-form-advanced.php

    r6768 r6788  
    9191<?php wp_nonce_field( 'autosave', 'autosavenonce', false ); ?>
    9292<?php wp_nonce_field( 'closedpostboxes', 'closedpostboxesnonce', false ); ?>
     93<?php wp_nonce_field( 'samplepermalink', 'samplepermalinknonce', false ); ?>
    9394</div>
    9495
  • trunk/wp-admin/js/slug.js

    r6761 r6788  
    1515            post_id: post_id,
    1616            new_slug: new_slug,
    17             cookie: document.cookie}, function(data) {
     17            samplepermalinknonce: jQuery('#samplepermalinknonce').val()}, function(data) {
    1818                jQuery('#sample-permalink').html(data);
    1919                b.html(revert_b);
Note: See TracChangeset for help on using the changeset viewer.