Ticket #15928: 15928.3.patch
File 15928.3.patch, 824 bytes (added by , 11 years ago) |
---|
-
wp-includes/functions.php
1556 1556 * @return array See above for description. 1557 1557 */ 1558 1558 function wp_upload_dir( $time = null ) { 1559 $siteurl = get_ option( 'siteurl');1559 $siteurl = get_site_url(); 1560 1560 $upload_path = trim( get_option( 'upload_path' ) ); 1561 1561 1562 1562 if ( empty( $upload_path ) || 'wp-content/uploads' == $upload_path ) { … … 1570 1570 1571 1571 if ( !$url = get_option( 'upload_url_path' ) ) { 1572 1572 if ( empty($upload_path) || ( 'wp-content/uploads' == $upload_path ) || ( $upload_path == $dir ) ) 1573 $url = WP_CONTENT_URL . '/uploads';1573 $url = content_url( 'uploads' ); 1574 1574 else 1575 1575 $url = trailingslashit( $siteurl ) . $upload_path; 1576 1576 }