#2143 closed defect (bug) (fixed)
Internationalize WordCamp Dashboard Widgets plugin
Reported by: | iandunn | Owned by: | iandunn |
---|---|---|---|
Milestone: | Priority: | low | |
Component: | WordCamp Site & Plugins | Keywords: | good-first-bug has-patch |
Cc: |
Description
The WordCamp Dashboard Widgets plugin needs to be internationalized.
The escaping translation functions (esc_html__()
, esc_attr_e()
, etc) should be used instead of their non-escaping counterparts.
Attachments (2)
Change History (10)
#4
@
8 years ago
@chandrapatel Thanks for the patch! There are a few instances where the translation strings are not being escaped, probably because they contain HTML. In these cases, the strings should still be sanitized with wp_kses()
. Something like this:
<?php printf( wp_kses( __( 'Please send us <a href="%s">the "about" text and banner image</a> for your central.wordcamp.org page.', 'wordcamporg' ), array( 'a' => array( 'href' => true ) ) ), 'https://make.wordpress.org/community/handbook/wordcamp-organizer/first-steps/web-presence/your-page-on-central-wordcamp-org/' ); ?>
#5
@
8 years ago
Hi @coreymckrill
I've made changes as you suggested. See 2143.1.patch
Please check and let me know if its fine.
#7
@
8 years ago
@chandrapatel Thanks, and nice work!
A couple of suggestions for your next patch:
- For PHP files, your indents should be with tab characters rather than spaces.
- Keep the patch focused on the ticket issue. This patch had a couple of miscellaneous changes to comment punctuation and additional commas on array items. These aren't bad, but they distract from the important changes in the patch, so it's best to include them separately.
Note: See
TracTickets for help on using
tickets.
Hi @iandunn
I will work on it.