Retrieve the available language from a given page


In Grav, I have some pages created and translated in Spanish only. They have been created from the admin panel. (see attached screenshot).

This page is accessible with the /es/ prefix and is in Spanish. But I can access the page using /fr/for example. And I would like to avoid that (redirect maybe). Is it possible from a given page to know which language is available?


Screen Shot 2016-11-24 at 12

It’s possible using the page object: