Changeset 8626
- Timestamp:
- 08/12/2008 08:58:46 PM (16 years ago)
- Location:
- branches/2.6/wp-admin
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/2.6/wp-admin/edit-form-advanced.php
r8579 r8626 74 74 <input type="hidden" id="post_type" name="post_type" value="<?php echo $post->post_type ?>" /> 75 75 <input type="hidden" id="original_post_status" name="original_post_status" value="<?php echo $post->post_status ?>" /> 76 <input name="referredby" type="hidden" id="referredby" value="<?php 77 if ( !empty($_REQUEST['popupurl']) ) 78 echo clean_url(stripslashes($_REQUEST['popupurl'])); 79 else if ( strpos( wp_get_referer(), '/wp-admin/' ) === false && $post_ID && url_to_postid(wp_get_referer()) == $post_ID ) 80 echo 'redo'; 81 else 82 echo clean_url(stripslashes(wp_get_referer())); 83 ?>" /> 76 <input name="referredby" type="hidden" id="referredby" value="<?php echo clean_url(stripslashes(wp_get_referer())); ?>" /> 84 77 <?php if ( 'draft' != $post->post_status ) wp_original_referer_field(true, 'previous'); ?> 85 78 -
branches/2.6/wp-admin/edit-page-form.php
r8579 r8626 31 31 $user_ID = (int) $user_ID; 32 32 33 $sendto = clean_url(stripslashes(wp_get_referer()));34 35 if ( 0 != $post_ID && $sendto == get_permalink($post_ID) )36 $sendto = 'redo';37 33 ?> 38 34 … … 61 57 <input type="hidden" id="post_type" name="post_type" value="<?php echo $post->post_type ?>" /> 62 58 <input type="hidden" id="original_post_status" name="original_post_status" value="<?php echo $post->post_status ?>" /> 63 <input name="referredby" type="hidden" id="referredby" value="<?php 64 if ( strpos( wp_get_referer(), '/wp-admin/' ) === false && $post_ID && url_to_postid(wp_get_referer()) == $post_ID ) 65 echo 'redo'; 66 else 67 echo clean_url(stripslashes(wp_get_referer())); 68 ?>" /> 59 <input name="referredby" type="hidden" id="referredby" value="<?php echo clean_url(stripslashes(wp_get_referer())); ?>" /> 69 60 <?php if ( 'draft' != $post->post_status ) wp_original_referer_field(true, 'previous'); ?> 70 61 -
branches/2.6/wp-admin/post.php
r8033 r8626 37 37 $location = $_POST['referredby']; 38 38 $location = remove_query_arg('_wp_original_http_referer', $location); 39 if ( $_POST['referredby'] == 'redo' ) 40 $location = get_permalink( $post_ID ); 41 elseif ( false !== strpos($location, 'edit.php') ) 39 if ( false !== strpos($location, 'edit.php') ) 42 40 $location = add_query_arg('posted', $post_ID, $location); 43 41 elseif ( false !== strpos($location, 'wp-admin') )
Note: See TracChangeset
for help on using the changeset viewer.