TaylorH
22 Jan 2010, 01:35 AM
I want to know how to allow a user to change a websites look. It websites that have different themes or color schemes, like on the Gamespot homepage. How is this accomplished?
I have two theories.
The button changes a variable that causes the HTML file to reference a different CSS file. Ie 'IF x = 1 THEN reference stylesheet1.css' 'IF x = 2 THEN reference stylesheet2.css'.
Or
The button changes a variable that causes the HTML file to reference a different part of the CSS file. Ie 'IF x = 1 THEN reference top half of stylesheet.css' 'IF x = 2 THEN reference bottom half of stylesheet.css'.
Or am I completely off-base here?
I am looking for a solution to change an entire website's look, not just it's color scheme, but layout and everything, based on the user's input.
Thoughts?
I have two theories.
The button changes a variable that causes the HTML file to reference a different CSS file. Ie 'IF x = 1 THEN reference stylesheet1.css' 'IF x = 2 THEN reference stylesheet2.css'.
Or
The button changes a variable that causes the HTML file to reference a different part of the CSS file. Ie 'IF x = 1 THEN reference top half of stylesheet.css' 'IF x = 2 THEN reference bottom half of stylesheet.css'.
Or am I completely off-base here?
I am looking for a solution to change an entire website's look, not just it's color scheme, but layout and everything, based on the user's input.
Thoughts?