Tags:
create new tag
, view all tags

Question

Is it possible to Set Web level variables from an include file? I tried placing a %INCLUDE... in the WebPreferences page and it displayed correctly on the page. However the variables were no longer visible to other pages. When the Set VARNAME = was coded directly in the page, the variables were included.

Environment

TWiki version: TWikiRelease02Sep2004
TWiki plugins: DefaultPlugin, EmptyPlugin, InterwikiPlugin
Server OS: linux
Web server: Apache/2.0.40 (Red Hat Linux)
Perl version: 5.8.6
Client OS: windows xp pro
Web Browser: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.7.5) Gecko/20041107 Firefox/1.0
Categories: Missing functionality

-- BradTaylor - 18 Jan 2005

Answer

Preferences do not follow INCLUDEs. However, you can use a SpreadSheetPlugin formula in an INCLUDEd file that sets a variable, e.g. %CALC{$SET(dinner, Sushi)}%, then use the variable in your topic.

-- PeterThoeny - 19 Jan 2005

Bug report filed: Bugs:Item4546

-- VickiBrown - 04 Sep 2007

Feature proposal: Codev.INCLUDEdSetvariablesshouldwork

-- VickiBrown - 07 May 2008

 
Topic revision: r5 - 07 May 2008 - 17:18:03 - VickiBrown
 
This site is powered by the TWiki collaboration platformCopyright © by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback