Closed Bug 719668 Opened 12 years ago Closed 12 years ago

Go to English doc page if translated page is not available

Categories

(developer.mozilla.org Graveyard :: Editing, defect)

x86
macOS
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: jswisher, Unassigned)

References

Details

(Whiteboard: u=user c=wiki s=2012-07-03 p=1)

As in English, if a user follows a link to a page that does not exist in a given locale, MindTouch helpfully redirects them to the locale home page. However, users expect that if an English version of the page is available, they should get that page instead.


http://mdn.uservoice.com/forums/51389-mdn-website-feedback-http-developer-mozilla-org/suggestions/2516132-fixing-german-language-specific-url-forwarding-on-

http://mdn.uservoice.com/forums/51389-mdn-website-feedback-http-developer-mozilla-org/suggestions/2511579-improve-the-translated-web-pages-of-mdn-bad-li

The problem is that if the localized URL does not exist, there is nothing to associate it with a corresponding English URL (whereas there is a template to make this association on real pages). The path after the language code is often the same across languages, but this is not required; some translators leave it the same but some don't. 

Two approaches I can think of:
1. If a localized URL does not exist, try replacing the language code with "en" and see if that URL exists; if not, redirect as usual.
2. Go through all localized links, especially in Django pages, and verify that they point to existing pages.

Given that we have no fix for the general redirect-for-nonexistant-page problem, #1 seems unlikely to be doable. #2 is doable but extremely tedious.
Yeah, #1 is in dekiwiki code so we won't fix that.

#2 is already done programmatically: https://github.com/mozilla/kuma/blob/master/apps/devmo/helpers.py#L75

Though if you know of any links that are pointing to non-existent localized pages reopen this with a list so we can wrap them in the helper function.
Status: NEW → RESOLVED
Closed: 12 years ago
Resolution: --- → WONTFIX
As said in bug 674702 I've corrected German links to point to /en/. However, my changes don't seem to be committed via verbatim. I've just committed my changes again (hopefully now correctly).
Whiteboard: u=user c=wiki s=2012-07-03 p=
Version: Deki → Kuma
I *think* this is already covered in Kuma. If you visit a non-en-US URL for which there is an equivalent path in /en-US, you get a "fallback" page. 

That's en-US content with a banner that says basically "This page has not yet been translated for your locale, want to do it?"
Whiteboard: u=user c=wiki s=2012-07-03 p= → u=user c=wiki s=2012-07-03 p=1
Depends on: 756263
Blocks: 756263
No longer depends on: 756263
Jean-Yves, Florian, Janet: Thoughts on the implementation described in comment 4 and comment 5?
This is live on https://developer-dev.allizom.org/de/docs/CSS (note de/CSS doesn't exist there only because we didn't migrate it.)
Status: REOPENED → RESOLVED
Closed: 12 years ago12 years ago
Resolution: --- → FIXED
Les: In the link you posted in comment 5, the string that appears above the article is:

"Our volunteers haven't translated this article into català yet. Join us and help get the job done!"

Is the message itself in English only because it hasn't been translated to català yet? If that's the case, we might want to be extra sure we have a version of this for every locale.
(In reply to John Karahalis [:openjck] from comment #8)

> Is the message itself in English only because it hasn't been translated to
> català yet?

Yes, for example, try this one:
    https://developer-new.mozilla.org/nl/docs/HTML/HTML5

> If that's the case, we might want to be extra sure we have a
> version of this for every locale.

That's up to the localizers - not a whole lot we (the dev team) can do to ensure that, other than ask nicely and offer cake / beer / local delicacies.
(In reply to Les Orchard [:lorchard] from comment #9)
> That's up to the localizers - not a whole lot we (the dev team) can do to
> ensure that, other than ask nicely and offer cake / beer / local delicacies.

Totally. I'll be sure it's on our radar.
Version: Kuma → unspecified
Component: Docs Platform → Editing
Product: developer.mozilla.org → developer.mozilla.org Graveyard
You need to log in before you can comment on or make changes to this bug.