GetSimple Support Forum

Full Version: Page "variants" somewhat like i18n languages
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hi,

I've a request to build a site where are few pages have two variants, "private" or "business". She really wants one to pick a "mode" when entering the site, which then determines which "variant" is seen.

I've used the i18n plugin before, for multi-language sites and it has worked great. What I need now is basically the same, but the parameter is not which language, but which mode is active.

Ideal scenario:
I've got two languages (modes): private and business.
All pages show the private variant per default.
If the user explicitly clicks a "business" link in the site header, the pages that have an explicit "business" variant will display that, or else fall back to the private variant.

I hope the intent is clear.

It seems a bit wrong to abuse the i18n plugin by picking a random language for the "business" mode, and I can't choose an arbitrary language code like "business" since the plugin wont accept an invalid language code.

Any ideas for a nice solution here?
You could do it that way just using copies of the same language renamed to some valid string format you can even modify the lang format via undocumented vars in the plugin.

Not sure why you can't just make 2 versions of each page though and use custom code to toggle between them using a custom component or something.