[wp-trac] [WordPress Trac] #9471: Attachments uploaded before post is saved or autosaved get 0 (zero) for post_parent (instead of temp_id value)

WordPress Trac wp-trac at lists.automattic.com
Thu Nov 5 22:16:59 UTC 2009


#9471: Attachments uploaded before post is saved or autosaved get 0 (zero) for
post_parent (instead of temp_id value)
--------------------------+-------------------------------------------------
 Reporter:  aesqe         |       Owner:  scribu          
     Type:  defect (bug)  |      Status:  accepted        
 Priority:  normal        |   Milestone:  2.9             
Component:  Media         |     Version:  2.8             
 Severity:  blocker       |    Keywords:  has-patch tested
--------------------------+-------------------------------------------------

Comment(by azaozz):

 Could probably do
 {{{
 $temp_ID = time() . rand(10000000, 99999999);
 }}}
 But still this is only a workaround.

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


More information about the wp-trac mailing list