﻿id,summary,reporter,owner,description,type,status,priority,milestone,component,version,severity,resolution,keywords,cc
12323,Original images linked when using [gallery] instead of edited images.,materdaddy,,"When using the built-in [gallery] in WPMU, any images you've edited using the built-in ""media"" editing will have anchors that point to the original image rather than the edited image.

Steps to reproduce:
  * Upload images to a post.
  * Rotate an image and save.
  * Use [gallery link=""file""] in your post.

Expected Behavior:
  Gallery shown in your post with the edited images, clicking one should show the full sized edited file.
Actual Behavior:
  Gallery is shown in your post with the edited images, however clicking one results in a link to the original (non-rotated) images.


Suspect:
  wp-includes/post.php - function wp_get_attachment_url()

  There is a section of code commented out for MU that says it breaks the image upload path for MU.  This is untrue: The ""elseif"" check on wp-content/uploads will evaluate false, then the ""else"" will just concatenate the upload's baseurl to the filename resulting in a correct URL if it weren't commented out.

  Because that section of code is commented out, the ""$url"" variable is still empty after that if block, and the guid is used instead, which apparently is the unaltered original image.


Particulars:
  * WPMU 2.9.1.1
  * Apache2 2.2.11(Ubuntu)
  * PHP 5.2.6-3ubuntu4 with Suhosin-Patch 0.9.6.2
  * uname: Linux 2.6.30-rc6 #2 PREEMPT Wed May 20 05:42:04 MDT 2009 armv5tel GNU/Linux
  * mysql Ver 14.12 Distrib 5.0.75, for debian-linux-gnu (arm) using readline 5.2",defect (bug),closed,normal,,Media,2.9.1,minor,worksforme,multisite,
