Sebastian Kannengiesser wrote:
Hi guys,
I once configured different layouts for my different spaces. Now I decided, that all spaces should look in a common way. Actually, changing the Global layout in the administration does not overwrite the space-specific layouts. How can I remove those specific layout configurations, so every space takes the global configuration?
What do you understand by layout? The panels located on the left/right side? Try this: #foreach($spacePref in $xwiki.searchDocuments(", BaseObject prefs, StringProperty panels where doc.name = 'WebPreferences' and prefs.name = doc.fullName and prefs.className = 'XWiki.XWikiPreferences' and panels.id.id = prefs.id and (panels.id.name = 'leftPanels' or panels.id.name = 'rightPanels') and panels.value <> ''")) #set($spacePrefsDoc = $xwiki.getDocument($spacePrefs)) #set($spacePrefsObj = $spacePrefsDoc.getObject('XWiki.XWikiPreferences')) $spacePrefsObj.set('leftPanels', '') $spacePrefsObj.set('rightPanels', '') $spacePrefsDoc.save() #end -- Sergiu Dumitriu http://purl.org/net/sergiu/