SOLVED

How to add a Quick Launch node with different titles to support multi languages

%3CLINGO-SUB%20id%3D%22lingo-sub-1476775%22%20slang%3D%22de-DE%22%3EHow%20to%20add%20a%20Quick%20Launch%20node%20with%20different%20titles%20to%20support%20multi%20languages%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1476775%22%20slang%3D%22de-DE%22%3E%3CP%3EHi%20community%2C%3C%2FP%3E%3CP%3EI%20want%20to%20deploy%20site%20collections%20with%20Powershell%2C%20preverable%20with%20PNP%20modules.%20My%20main%20problem%20is%2C%20that%20I%20have%20to%20create%20a%20Quick%20Launch%20for%20a%20multi%20culture%20environment%20and%20the%20node%20titles%20have%20to%20be%20different%2C%20i.e.%20English%20-%20Contracts%20and%20in%20German%20Contracts.%26nbsp%3B%3C%2FP%3E%3CP%3EI%20can%20do%20this%20manually%20by%20changing%20the%20browser%20language%2C%20but%20so%20far%20I%20couldn't%20find%20any%20solution%20in%20the%20web.%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3ECould%20you%20please%20help%20me%3F%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EChild%3C%2FP%3E%3CP%3EChris%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-LABS%20id%3D%22lingo-labs-1476775%22%20slang%3D%22de-DE%22%3E%3CLINGO-LABEL%3EAdmin%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3EDeveloper%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3EPowershell%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3ESharePoint%20Online%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1570371%22%20slang%3D%22en-US%22%3ERe%3A%20How%20to%20add%20a%20Quick%20Launch%20node%20with%20different%20titles%20to%20support%20multi%20languages%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1570371%22%20slang%3D%22en-US%22%3E%3CP%3EAfter%20several%20days%20of%20R%26amp%3BD%20I%20found%20a%20way%20to%20manage%20the%20quicklaunch%20in%20a%20multi-language%20environment%20with%20PowerShell.%20You%20can%20find%20an%20example%20script%20attached.%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EThe%20example%20script%20has%20this%20funcitonality%3C%2FP%3E%3CUL%3E%3CLI%3E%22get-QuickLaunch%22%3CBR%20%2F%3EThe%20complete%20quicklaunch%20structure%20is%20requested%20for%20english%20and%20german%20language%20settings%20and%20returned%20as%20an%20array.%3C%2FLI%3E%3CLI%3E%22add-SingleNode%22%3CBR%20%2F%3EA%20new%20main%20navigation%20element%20is%20set%20with%20language%20settings%20in%20german%20and%20english%3CBR%20%2F%3E%3CBR%20%2F%3E%3C%2FLI%3E%3CLI%3E%22new-Quicklaunch%22%3CBR%20%2F%3ECurrent%20quicklaunch%20is%20completly%20replaced%20in%20'two'%20steps%20with%20a%20new%20quicklaunch%20in%20german%20and%20english.%20The%20Nodes%20are%20the%20same%20as%20before%2C%20but%20titles%20are%20extended%20with%20current%20time.%26nbsp%3B%3CBR%20%2F%3EIt%20would%20be%20possible%20to%20add%20each%20node%20separatly%2C%20but%20in%20our%20use%20case%2C%20it%20wouldn't%20be%20nice%2C%20when%20the%20user%20sees%20the%20growing%20navigation%20tree.%20To%20avoid%20this%2C%20I%20have%20implemented%20a%20three%20step%20approach.%20First%20create%20the%20tree%20with%20all%20nodes%20and%20my%20node%20identifiers.%20Second%20and%20third%20step%20update%20the%20language%20versions.%26nbsp%3B%3C%2FLI%3E%3C%2FUL%3E%3CP%3EThe%20only%20preconditions%20to%20run%20the%20script%20is%20that%20you%20have%26nbsp%3B%3C%2FP%3E%3CUL%3E%3CLI%3EApp-Security%20authentification%20configured%3C%2FLI%3E%3CLI%3EApply%20your%20App-Security%20informations%20at%20the%20beginning%20of%20the%20Script%20(lines%203-6)%3C%2FLI%3E%3CLI%3ESet%20the%20Site%20URL%20in%20line%208%3CP%3E%26nbsp%3B%3C%2FP%3E%3C%2FLI%3E%3CLI%3EApp%20needs%20SiteCollection%20admin%20rights%20to%20access%20the%20SharePoint%20site%3C%2FLI%3E%3C%2FUL%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EIt%20would%20be%20nice%2C%20if%20you%20could%20send%20me%20feedback%20to%20my%20example.%3C%2FP%3E%3CP%3ERegards%3C%2FP%3E%3CP%3EChristian%3C%2FP%3E%3C%2FLINGO-BODY%3E
Highlighted
Occasional Contributor

Hi community,

I want to deploy site collections with Powershell, preverable with PNP modules. My main problem is, that I have to create a Quick Launch for a multi culture environment and the node titles have to be different, i.e. English - Contracts and in German Verträge. 

I can do this manually by changing the browser language, but so far I couldn't found any solution in the web. 

 

Could you please help me?

 

Kind regards

Chris

1 Reply
Highlighted
Best Response confirmed by Chris10250 (Occasional Contributor)
Solution

After several days of R&D I found a way to manage the quicklaunch in a multi-language environment with PowerShell. You can find an example script attached. 

 

The example script has this funcitonality

  • "get-QuickLaunch"
    The complete quicklaunch structure is requested for english and german language settings and returned as an array.
  • "add-SingleNode"
    A new main navigation element is set with language settings in german and english

  • "new-Quicklaunch"
    Current quicklaunch is completly replaced in 'two' steps with a new quicklaunch in german and english. The Nodes are the same as before, but titles are extended with current time. 
    It would be possible to add each node separatly, but in our use case, it wouldn't be nice, when the user sees the growing navigation tree. To avoid this, I have implemented a three step approach. First create the tree with all nodes and my node identifiers. Second and third step update the language versions. 

The only preconditions to run the script is that you have 

  • App-Security authentification configured
  • Apply your App-Security informations at the beginning of the Script (lines 3-6)
  • Set the Site URL in line 8

     

  • App needs SiteCollection admin rights to access the SharePoint site

 

It would be nice, if you could send me feedback to my example.

Regards

Christian