If I wanted to pass a query string variable to a survey indicating which survey group to use for rendering the survey, is it possible to then dynamically process the variable and render the survey with the correct look and feel?
I understand there may be development involved which is ok, just looking for the best approach to take.
The easiest example I can think of for this question is "light" mode versus "dark" mode. For users who prefer light mode, we would render surveys on a light back ground. Conversely, for users who prefer dark mode, we would render surveys on a black background with light lettering.
Light versus dark is just a simplistic example. For our potential use case, we might have 4 or more survey groups that could be selected as a preference.
(for example's sake, let's use a hidden list-radio with question code "control")
Having done that...
1) For styling, you can apply a class to the <body> element by extending the theme and modifying the <body> tag in layout_global.twig something like this:
I currently have PHP code that extracts query string parameters from the inbound URL and stores the values in session so I have access to them throughout a survey. This lets me know what the desired "look and feel" parameter should be without having to us a hidden question on every survey constructed.
I could write a bunch of CSS classes to be used for each look and feel but I was hoping to utilize the current structures in LimeSurvey which already accomplish Theming.
I was hoping for an extensible way to "swap" the "light" survey group for the "default" survey group when the survey request is made. Maybe it's a pipe dream and the only way is to re-write all the CSS available within the SurveyGroup but I am ever the optimist.
Thank you again for your reply. I do appreciate your time and willingness to help.