Zen Follower
- Join Date:
- May 2010
- Location:
- Cyberspace
- Posts:
- 387
- Plugin Contributions:
- 0
change size of the "Dropdown Menu"
Hi!
Does anyone know if it's possible to change (preferably lock) the size of the dropdown menu..?
Thanks/Jacob
Views: 1,093
Zen Follower
Hi!
Does anyone know if it's possible to change (preferably lock) the size of the dropdown menu..?
Thanks/Jacob
Zen Follower
Need a little more information...
What menu, where is it, maybe a url to take a look? Most settings can be done in a css file however more info is needed.
Zen Follower
Hi Paul! Thanks for looking at it. The url is here:http://centuriongames.se/index.php?main_page=product_info&cPath=1_58_65&products_id=170
:) /Jacob
Black Belt
Now that we can see it, which dropdown do you mean? "Tillverkare"?
And how do you mean "change the size"? Make it a fixed menu display of all the items instead of a dropdown?
Zen Follower
Hi gjh42! Thanks for also having a look at this. I found out that I could "lock" the position of the element (Dropdown Menu) by setting the width of "attribsSelect" so the Dropdown wouldn't move around (or rather move to the left) based on it's size.. here's comes the charming part.. it's not possible to press the Dropdown Menu (it's like frozen..) :yes:
Forgot to mention, we're talking about the Dropdown Menu on the tpl_product_information_display.
/Jacob
Black Belt
To keep the select or dropdown box positoioned the same distance from the left edge no matter what the length of the name, add to your stylesheet
h4.optionName {width: 106px;}
or whatever you want. This will apply to all attributes, not just ones with a label of class .attribsSelect.
The dropdown appears to be frozen because you have used big negative margin-top and padding-top to move #cartAdd around. Change those to smaller dimensions and the dropdown will no longer be screened.
Zen Follower
Ok. Thanks.. I'll try that.. is 106px some sort of standard?? 'Cause I've seen it on some other sites.. thanks!
Will I be able to keep the lay-out if I use smaller margins for the add-to-cart button?/Jacob
Black Belt
Not at all. It may correspond to some common em size, but has no significance, beside being right in the range that will usually give good results. I used it because it was already in your CSS. On my own, I would have said 100px or 10em.
Zen Follower
I missed that part where 106px was already in my css (that's what happens when you're too ######..) referring to all the #### are we not allowed to write g@y here??
Can I ask why you wrote this particular part of code without a space ('h4.optionName')??
/JAcob
Black Belt
The forum has spam/pron filters that automatically censor certain words (even if they are actually just part of a completely different word). Kind of annoying sometimes.
The absense of a space there is essential to the meaning.
h4.optionName would mean "h4 elements with class optionName".
h4 .optionName would mean "elements with class optionName inside an h4".
Zen Follower
Thanks. It would have taken me quite long to figure that out for myself so thanks. I've worked my site for seven months now [being both more and less active during this time] and it had not been possible without tips like these.. :D
Zen Follower
Great! You just solved the issue with the frozen "Dropdown Menu" and without any major changes to the lay-out.
I don't now what I was thinking writing that code... (maybe it was something #####..)
Tell staff why this post should be reviewed.