what should be the string context when using t('view') or t('View')

t('View', array(), array('context' => ?));

? = 'list of items'
? = 'views module'
? = 'noun'
???

Comments

dawehner’s picture

I like views module. The translators gets the knowledge immediately.

esmerel’s picture

Status: Active » Postponed (maintainer needs more info)

Pasqualle, did you get this figured out?

pasqualle’s picture

no

esmerel’s picture

This isn't going to get any help without a) some specifics of what and where you're trying to make changes and b) changing the status of the issue out of 'postponed'

esmerel’s picture

Status: Postponed (maintainer needs more info) » Closed (cannot reproduce)

No updates for more than 30 days.

tobiasb’s picture

Title: t('view') context? » Use context for some strings - D7
Status: Closed (cannot reproduce) » Active

Views (Modulname)
Block/block (Displaytype)

...to be continue.

tobiasb’s picture

Assigned: Unassigned » tobiasb
merlinofchaos’s picture

I believe what Pasqualle is asking is for us to add context to the t() call when we use the word View, so that the translation system can tell if it's View, the verb (as often used in tabs) or View the noun.

Is that correct, Pasqualle?

merlinofchaos’s picture

If that's the case, this issue would've benefited significantly from an explanation. Please understand that most Drupal developers do not understand the intricacies of translation.

esmerel’s picture

Category: support » task

Merlin believes that this is actually supposed to be "please provide a context around the word "View" so that it can be determined if this is something like "Look at the View" rather than "view the page". Moving to a FR. As such, it's a feature request which is potentially fulfillable by the translation system and is being moved to a task.

merlinofchaos’s picture

Assigned: tobiasb » Unassigned
Category: task » support
merlinofchaos’s picture

Also, now that I think on it, I have no idea how to provide context.

pasqualle’s picture

Issue tags: +string context

Actually we are using t('View') on the admin page of quictabs module, and the problem is that it can't be translated correctly (at least not in D6). So I want to add a context to this t() call but I would like to use an unified context name (so other modules can use the same context, and translators have to translate it only once)..
As I remember I did not find any t('view') in the views module, so probably this isn't a problem in views.

merlinofchaos’s picture

Oh I see. Hmm.

I don't have an immediate answer for the context. That said, if you come up with a good answer, it should be documented so that others can use it. There's a few translation issues, maybe we should put all of them together in an advanced help file. In particular we can discuss the - any - and the like. We can also talk about the translation plugin, that needs some user documentation anyway.

iamjon’s picture

Title: Use context for some strings - D7 » Update documentation to reflect translation intricacies and workarounds
Category: support » task

Marking this as a task based on #14 and changing the title to reflect change.

mustanggb’s picture

Issue summary: View changes
Status: Active » Closed (outdated)

Closing this as outdated to tidy up a bit around here. If you're still having problems with the latest release please create a new issue.