Changeset 8380 for sites/trunk/wordpress.tv/public_html/wp-content/themes/wptv2/plugins/wordpresstv-anon-upload/anon-upload.php
- Timestamp:
- 03/01/2019 09:03:33 AM (7 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sites/trunk/wordpress.tv/public_html/wp-content/themes/wptv2/plugins/wordpresstv-anon-upload/anon-upload.php
r7675 r8380 24 24 } 25 25 26 $redir = home_url( 'submit-video' ); 26 $redir = home_url( '/submit-video/' ); 27 28 // Fields to prefill 29 $keep_fields = array( 30 'wptv_video_wordcamp', 31 'wptv_uploaded_by', 32 'wptv_email', 33 'wptv_language', 34 'post_category', // 'wptv_categories', 35 'wptv_producer_username', 36 'wptv_event', 37 ); 27 38 28 39 if ( $this->success ) { … … 30 41 } elseif ( $this->errors ) { 31 42 $redir = add_query_arg( array( 'error' => $this->errors ), $redir ); 43 44 // Video upload failed, include the video-specific fields in pre-fill. 45 $keep_fields[] = 'wptv_video_title'; 46 $keep_fields[] = 'wptv_speakers'; 47 $keep_fields[] = 'wptv_video_description'; 48 $keep_fields[] = 'wptv_slides_url'; 49 32 50 } else { 51 $keep_fields = array(); 33 52 $redir = add_query_arg( array( 'error' => 5 ), $redir ); 53 } 54 55 // Keep some fields. 56 if ( $keep_fields ) { 57 $redir = add_query_arg( 58 urlencode_deep( 59 array_intersect_key( 60 $_POST, 61 array_flip( $keep_fields ) 62 ) 63 ), 64 $redir 65 ); 34 66 } 35 67
Note: See TracChangeset
for help on using the changeset viewer.