Make WordPress Core

Opened 6 years ago

Closed 6 years ago

Last modified 6 years ago

#19942 closed defect (bug) (fixed)

Simplify themes preview link building

Reported by: ocean90 Owned by: nacin
Milestone: 3.4 Priority: normal
Severity: minor Version: 2.8
Component: Themes Keywords: has-patch commit
Focuses: Cc:


Just use home_url().

Attachments (1)

19942.patch (1.7 KB) - added by ocean90 6 years ago.

Download all attachments as: .zip

Change History (4)

6 years ago

#1 @SergeyBiryukov
6 years ago

  • Keywords commit added

#2 @nacin
6 years ago

  • Owner set to nacin
  • Resolution set to fixed
  • Status changed from new to closed

In [19811]:

Use home_url() rather than get_option() + is_ssl(). props ocean90, fixes #19942.

#3 @koopersmith
6 years ago

Just to note that this was actually incorrect if we wanted to match the admin's scheme — home_url() defaults to 'http' when is_admin() is true. See #20137, [20051].

However, now that the theme customizer is in core (#19910, [19995]) this preview code will likely be used for no-js previewing, which does *not* need to match the admin's scheme as it will load in a new tab.

Note: See TracTickets for help on using tickets.