[wp-trac] [WordPress Trac] #50592: Confusing usage of home_url()

WordPress Trac noreply at wordpress.org
Tue Jul 7 14:44:02 UTC 2020


#50592: Confusing usage of home_url()
--------------------------+---------------------
 Reporter:  Chouby        |       Owner:  (none)
     Type:  defect (bug)  |      Status:  new
 Priority:  normal        |   Milestone:  5.5
Component:  Sitemaps      |     Version:  trunk
 Severity:  normal        |  Resolution:
 Keywords:  has-patch     |     Focuses:
--------------------------+---------------------
Changes (by Chouby):

 * keywords:   => has-patch


Comment:

 For information, I looked at other places of WordPress how is handled this
 type of case, and I found:
 `$permalink = home_url( '?p=' . $post->ID );` in `get_permalink()`.
 `$link = home_url( '?page_id=' . $post->ID );` in `_get_page_link()`.

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/50592#comment:2>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list