WordPress.org

Make WordPress Core

Opened 2 years ago

Closed 2 years ago

Last modified 2 years ago

#25018 closed defect (bug) (invalid)

Hardcoded text in post-template.php

Reported by: leandroprz Owned by:
Milestone: Priority: normal
Severity: normal Version: 3.6
Component: Template Keywords:
Focuses: Cc:

Description

Hi,

I was looking for a way to split a page into several pages and found this.

I tried it on my blog and it worked just fine even though I thought it was only for WordPress.com.

Anyway, I noticed a problem with the translation. I get "Pages:" instead of "Páginas:" (I'm using a Spanish translation in wp-config.php).

I checked the WP translation website and the translation is fine. So I checked the post-template.php file and noticed there's hardcoded text there and that's why it's not being translated.

Please check lines 637:

		'before'           => '<p>' . __( 'Pages:' ),

641:

		'next_or_number'   => 'number',

643:

		'nextpagelink'     => __( 'Next page' ),

And 644:

		'previouspagelink' => __( 'Previous page' ),

This is my first bug report, hope it's okay.

Thanks.

Change History (5)

comment:1 follow-up: @knutsp2 years ago

  • Keywords reporter-feedback added

The lines you mention is not the cause of this translation error. The strings are inside the __() function that actually calls the translation. Besides, these values are only the default, in case the theme doesn't provide a value for the argument.

So this may be the result of a untranslatable string in your theme, given as argument to wp_link_pages. Please try with Twenty Thirteen and report back.

comment:2 @SergeyBiryukov2 years ago

  • Keywords needs-patch translation hardcoded text removed

comment:3 in reply to: ↑ 1 @leandroprz2 years ago

Thanks for the clarification. I tried with Twenty Thirteen and now I see the translation. So it seems my problem is with my theme.

Sorry I reported something that wasn't actually a bug.

Thanks again.

comment:4 @leandroprz2 years ago

  • Resolution set to invalid
  • Status changed from new to closed

comment:5 @SergeyBiryukov2 years ago

  • Keywords reporter-feedback removed
  • Milestone Awaiting Review deleted
Note: See TracTickets for help on using tickets.