[wp-trac] [WordPress Trac] #22829: Corrupt Gallery-Output

WordPress Trac noreply at wordpress.org
Sun Dec 9 05:05:16 UTC 2012


#22829: Corrupt Gallery-Output
--------------------------------+--------------------
 Reporter:  Bichareh            |       Owner:
     Type:  defect (bug)        |      Status:  new
 Priority:  normal              |   Milestone:  3.5
Component:  Gallery             |     Version:  trunk
 Severity:  normal              |  Resolution:
 Keywords:  close dev-feedback  |
--------------------------------+--------------------
Changes (by DrewAPicture):

 * keywords:  close => close dev-feedback


Comment:

 Replying to [comment:2 helenyhou]:
 > The gallery shortcode with IDs actually has no influence on the
 previous/next links on attachment pages.

 I think that's unfortunately kind of the point.

 I kept seeing these forum posts on basically the same issue and started
 poking around in `adjacent_image_link()`. I came to the conclusion that
 there actually ''is'' a demonstrable difference from 3.4.2 behavior.

 In 3.4.2, we had a form of "context" in the post parent. A post could only
 have one gallery so we could provide context to a media attachment page.
 Links to adjacent images would honor that context.

 But in 3.5, the context isn't being transferred from the gallery shortcode
 which now has images' explicit IDs. This works fine and awesome in the
 post view. But once you click one of the gallery images and are sent to
 its attachment page, you're effectively outside the context of the post.
 (I'm sure it's more complicated than that, but that's the gist). At this
 point, you're given adjacent image links but there doesn't seem to be a
 "post" context anymore so much as "anything" context.

 Looking at the permalinks, it's more obvious.

 In 3.4.2, this is what my permalink would look like for a gallery image
 attachment page:
 {{{
 gallery-test-3-4-2/drew-picture
 }}}

 All gallery-attached images have `gallery-test-3-4-2/` prepended, e.g.
 post context.

 In 3.5, it looks like this:
 {{{
 attachments/drew-picture
 }}}

 It makes sense that there's no prepended slug for the parent here but if
 we want to restore previous behavior, we need to find a way to tie images
 together on attachment pages, outside the post context.

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


More information about the wp-trac mailing list