The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
![]()
I have a column running down the right side of my forum homepage. I would like to have a profile variable that controls whether the user sees a 300px column or a 160px one. It's straightforward to create a variable and use a conditional to control this.
How do I let the user update the value from the right column of the homepage? I basically want a drop-down box that says "Narrow Layout" and "Wide Layout". When the user makes a selection, is there a way to use a Javascript onChange call to set the value? Or should I create a form that somehow reaches into the database and sets the value? I really need guidance on the best way to approach this. Please note that I don't want to use multiple styles to accomplish this. It leads to too much maintenance over the long run. |
#2
|
||||
|
||||
![]()
You COULD use an onchange call, but then it'd lock out non-JS enabled users and wouldn't be remembered.
If you really wanted that drop-down box, you'd have to see how vBulletin does the style chooser and replicate it. Have you tried using "child styles" to accomplish the task? |
#3
|
|||
|
|||
![]()
Dismounted, I've tried using child styles, but I haven't been thrilled with how it alters my development process. Is there a way to create a new style "between" the parent and the child?
After a day of reflection, you're right that this is probably the best way to do it. In reality, it's only the footer that changes in the child style. Can I just work on a copy of the parent style, download it, and then merge it back in with the original when I want to push it live? I'm assuming that for all different templates, vBulletin uses the content from the merged style? |
#4
|
||||
|
||||
![]()
Export the parent style, and then work on the XML. Import it back, overwriting the current parent style, and the changes will be merged. You may need to revert templates that are different in the child styles to get the changes, then reapply the changes to the child styles.
|
![]() |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|