Make WordPress Core

Opened 14 years ago

Closed 12 years ago

#16852 closed enhancement (fixed)

Don't output redundant dir="ltr" with language_attributes()

Reported by: bergius's profile bergius Owned by: nacin's profile nacin
Milestone: 3.5 Priority: normal
Severity: trivial Version: 3.1
Component: RTL Keywords: has-patch commit
Focuses: Cc:

Description

language_attributes() outputs dir="ltr" when is_rtl() returns false, but declaring the text direction as left-to-right is redundant.

Patch only outputs the dir attribute when the direction is right-to-left.

Attachments (3)

16852.diff (581 bytes) - added by bergius 14 years ago.
16852_2.diff (579 bytes) - added by bergius 14 years ago.
Tabs, not spaces.
16852_3.diff (548 bytes) - added by ramiy 13 years ago.

Download all attachments as: .zip

Change History (9)

@bergius
14 years ago

#1 @scribu
14 years ago

  • Summary changed from [PATCH] Don't output redundant dir="ltr" with language_attributes() to Don't output redundant dir="ltr" with language_attributes()

@bergius
14 years ago

Tabs, not spaces.

#2 @linuxologos
14 years ago

  • Cc linuxologos@… added

#3 @ramiy
13 years ago

bergius, i think you can remove - function_exists( 'is_rtl' ) .

@ramiy
13 years ago

#4 @nacin
12 years ago

  • Keywords needs-refresh added
  • Milestone changed from Awaiting Review to 3.5

I think the function_exists is still needed. See [14360].

#5 @nacin
12 years ago

  • Keywords commit added; needs-refresh removed

16852_2.diff is good.

#6 @nacin
12 years ago

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

In [21904]:

Stop outputting the default dir="ltr" in language_attributes(). props bergius. fixes #16852.

Note: See TracTickets for help on using tickets.