[wp-trac] [WordPress Trac] #15928: wp_get_attachment_url does not check for HTTPS

WordPress Trac noreply at wordpress.org
Tue Dec 18 01:31:45 UTC 2012


#15928: wp_get_attachment_url does not check for HTTPS
-------------------------------------+-----------------------------
 Reporter:  atetlaw                  |       Owner:
     Type:  defect (bug)             |      Status:  assigned
 Priority:  normal                   |   Milestone:  Future Release
Component:  Permalinks               |     Version:  3.0.3
 Severity:  normal                   |  Resolution:
 Keywords:  has-patch needs-testing  |
-------------------------------------+-----------------------------

Comment (by TedFolkman):

 The joy of discovery! The patches given above don't work with the version
 of functions.php in WP3.5 because the line numbers are changed, but by
 poking around I was able to figure out how to modify the patch file to
 make it work. I have no idea how to share it with others in the right way,
 but in the hopes that others will find it useful here is what I did:


 {{{
 Index: wp-includes/functions.php
 ===================================================================
 --- wp-includes/functions.php   (revision 18480)
 +++ wp-includes/functions.php   (working copy)
 @@ -1489,1 +1489,1 @@
 -       $siteurl = get_option( 'siteurl' );
 +       $siteurl = get_site_url();
 @@ -1503,1 +1503,1 @@
 -                       $url = WP_CONTENT_URL . '/uploads';
 +                       $url = content_url('uploads');

 }}}

 I hope this is not an inappropriate way to post this and that this doesn't
 screw up anyone else's blog, but it seems to work for me. If anyone knows
 how to do this the right way, I'd be most grateful!

-- 
Ticket URL: <http://core.trac.wordpress.org/ticket/15928#comment:32>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list