[wp-trac] [WordPress Trac] #10642: Cant insert image galleries into new posts (same on wordpress.com)

WordPress Trac wp-trac at lists.automattic.com
Sat Oct 31 11:56:10 UTC 2009


#10642: Cant insert image galleries into new posts (same on wordpress.com)
-------------------------------+--------------------------------------------
 Reporter:  kiprasm            |        Type:  defect (bug)
   Status:  new                |    Priority:  normal      
Milestone:  Future Release     |   Component:  Gallery     
  Version:  2.8.5              |    Severity:  normal      
 Keywords:  reporter-feedback  |  
-------------------------------+--------------------------------------------
Changes (by dd32):

  * keywords:  gallery => reporter-feedback


Old description:

> I'm having a problem inserting image galeries into new posts. In fact,
> this problem is also visible on wordpress.com !
>
> The problem is: you can't insert images as a gallery to a new post,
> through Quick Press or Posts -> Add New
> You can only insert photos as single images, by pressing "Insert into
> Post".
> The source of the problem is (as i understand it), the fact that a new
> post, while it is not yet auto saved as a draft, it does not have an ID.
> So you can't attach new photos to it, because they need an ID of the post
> they are being attached to as their post_parent.
>
> It is clearly visible, through Posts -> Add New. Try to add photos as a
> gallery right after you open up that page, you wont be able to do it.
> After pressing "Save all changes" the content of the Media popup will be
> blank, instead of a new Gallery tab appearing.
> But, if you type in post title, then wait for the draft to be saved (you
> can know when it is saved when the line with the permalink appears right
> below the post title input), the media uploader will work as expected.
>
> This is also why, media inserting as a gallery always works for edited
> posts (because they are already saved, therefore always have an id), and
> why it never works for Quick Press (because a post added through it never
> has an ID, because it only gets it when saved, and after you save it you
> can only edit it through Posts -> Edit).
>
> Inserting images directly into the post (one by one, not as a gallery
> that is) works, because they are directly inserted into the post contents
> and are not saved separately, therefore they don't need a post_parent.
>
> My questions are:
>
>     * Was this always the case? I mean was this problem introduced in 2.8
> or any other version ?
>     * Is there any sane way to fix this?

New description:

 I'm having a problem inserting image galeries into new posts. In fact,
 this problem is also visible on wordpress.com !

 The problem is: you can't insert images as a gallery to a new post,
 through Quick Press or Posts -> Add New
 You can only insert photos as single images, by pressing "Insert into
 Post".
 The source of the problem is (as i understand it), the fact that a new
 post, while it is not yet auto saved as a draft, it does not have an ID.
 So you can't attach new photos to it, because they need an ID of the post
 they are being attached to as their post_parent.

 It is clearly visible, through Posts -> Add New. Try to add photos as a
 gallery right after you open up that page, you wont be able to do it.
 After pressing "Save all changes" the content of the Media popup will be
 blank, instead of a new Gallery tab appearing.
 But, if you type in post title, then wait for the draft to be saved (you
 can know when it is saved when the line with the permalink appears right
 below the post title input), the media uploader will work as expected.

 This is also why, media inserting as a gallery always works for edited
 posts (because they are already saved, therefore always have an id), and
 why it never works for Quick Press (because a post added through it never
 has an ID, because it only gets it when saved, and after you save it you
 can only edit it through Posts -> Edit).

 Inserting images directly into the post (one by one, not as a gallery that
 is) works, because they are directly inserted into the post contents and
 are not saved separately, therefore they don't need a post_parent.

 My questions are:

     * Was this always the case? I mean was this problem introduced in 2.8
 or any other version ?
     * Is there any sane way to fix this?

--

Comment:

 It is expected that the Gallery tab is not available and/or shown until
 the Save All Changes button is clicked after uploading images, This is in
 order to allow the user to modify descriptions / ordering and have that
 saved, In addition to showing the user the full list of images which would
 be in the gallery (ie. not just those just uploaded).

 The white screen you're seeing after clicking save all changes however is
 weird, as it should reload straight to the gallery page.. And does for
 many other users.

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


More information about the wp-trac mailing list