The variations of gender could be looked up in two data tables 'male' and 'female', in such a way that:male##gender1 --> himfemale##gender1 --> hermale##gender2 --> Himfemale##gender2 --> Her
all variations of gender are text-reference lookups using either 'male' or 'female' (the titles of the two data tables) as the only variable
Hi Mans1. create a new tiddler and name this 'male'2. create a new tiddler and name this 'female'3. set the type of both of these tiddlers to 'data dictionary'4. in the text field of 'male' make entries like:gender1:himgender2:Himgender3:Mr... and so on5. in the text field of 'female' make entries like:gender1:hergender2:Her
gender3:Mrs... and so on6. when you want 'him' -- you can use the text reference {{male##gender1}} ... and so on7. when you want 'her' -- you can use the text reference {{female##gender1}} ... and so onI think in your use case you would want a variable as the name of the data tiddler -- so references might look something like {{$gender$##gender1}}, where the variable takes the value 'male' or 'female' as appropriate. I think you'll need a macro call to insert the variable before using the text-reference as the syntax I've used above won't work (this was for illustration only.)
I think in your use case you would want a variable as the name of the data tiddler -- so references might look something like {{$gender$##gender1}}, where the variable takes the value 'male' or 'female' as appropriate. I think you'll need a macro call to insert the variable before using the text-reference as the syntax I've used above won't work (this was for illustration only.)
\define getGender(gender,type)
{{$gender$##$type$}}
\end
<<getGender {{!!gender}} {{!!type}}>>\define getGender()
{{$(gender)$##$(type)$}}
\end
<$set name="gender" value={{!!gender}}>
<$set name="type" value={{!!type}}>
<<getGender>>
</$set></$set>