If it has not been reported in the bug tracker then it will be unlikely to be picked up on by the developers. In addition, we do not support modifications and this is an issue only with modified templates. Therefore, you should post at vBulletin.org for help with this.
Problem with Dropdown-Menus and CSS-Layout
Collapse
X
-
If it has not been reported in the bug tracker then it will be unlikely to be picked up on by the developers. In addition, we do not support modifications and this is an issue only with modified templates. Therefore, you should post at vBulletin.org for help with this.
@cscgal: If you are sure that a line works properly, but it causes a js error, the way to go is the try...catch constructComment
-
Hi, either you search this file for the right place, or you download the uncompressed version in your members area, then editing should be easierComment
-
I fixed the last bug of this code! Yay!! Look in the Vbulletin_menu.js, and replace the function: vB_Popup_Menu.prototype.set_menu_position = function(obj)
With:
Code:vB_Popup_Menu.prototype.set_menu_position = function(obj) { this.pos = this.fetch_offset(obj); this.leftpx = this.pos['left']; this.toppx = this.pos['top'] + obj.offsetHeight; var left_offset = obj.offsetLeft; var obj_orig = obj; var i = 0; while ((obj = obj.offsetParent) != null) i++; obj = obj_orig; while(i > 0) { obj = obj.offsetParent; left_offset += obj.offsetLeft; i--; } obj = obj_orig; if ((left_offset + this.menuobj.offsetWidth) >= document.body.clientWidth && (this.leftpx + obj.offsetWidth - this.menuobj.offsetWidth) > 0) { this.leftpx = this.leftpx + obj.offsetWidth - this.menuobj.offsetWidth; this.direction = 'right'; } else { this.direction = 'left'; } // move the pagenav menu to the calling object, so it appears to be styled like where it's displayed if (this.controlkey.match(/^pagenav\.\d+$/)) { obj.appendChild(this.menuobj); } this.menuobj.style.left = this.leftpx + 'px'; this.menuobj.style.top = this.toppx + 'px'; };
Comment
-
I am afraid it does not help when it is called for div's with position declared differently as vB allows us to use
I have the very same problem and I cannot agree to such behaviour of vB. Most of sites using external adservers must comply with RELATIVE positioning as well as z-index to avoid abnormal flash viewing.
Thus, changing positioning of the main layer to relative makes vB menu to show off the expected position.
It clearly does not look like a proper customer treatment here. Disappointing, I must say.Comment
-
Hey StGaensler! I WOULD BUY YOU A BEER RIGHT NOW IF I COULD! THIS CODE WORKS GREAT. THANK YOU VERY MUCH!!!!
Yes I have another solution
Edit clientscript/vbulletin_menu.js and replace function vB_Popup_Menu.prototype.fetch_offset (line 472 in vB 3.6.4) with following function:Code:vB_Popup_Menu.prototype.fetch_offset = function(obj) { var left_offset = obj.offsetLeft; var top_offset = obj.offsetTop; var obj_orig = obj; var obj_menu = document.getElementById(obj.id + '_menu'); var i = 0; while ((obj = obj.offsetParent) != null) i++; while ((obj_menu = obj_menu.offsetParent) != null) i--; obj = obj_orig; while(i > 0) { obj = obj.offsetParent; left_offset += obj.offsetLeft; top_offset += obj.offsetTop; i--; } return { 'left' : left_offset, 'top' : top_offset }; };
Comment
-
FIXED!!! I found the solution on jfusion forum, credit to the original poster
In the CSS I replaced "position:relative" with "position:inherit" for the DIVs that wrap the forum and now it works great!
The only problem is that adding code to Extra CSS Attributes (like that post say) didn't work for me so I had to edit the vbulletin CSS. Maybe I don't know how Extra CSS Attributes box works.Comment
-
Thanks for posting that it helped me solve a few issues with our forums■█► WireNine.com Web Hosting ► 8+ years in business!
■█► Shared Hosting, Reseller Hosting and VPS Hosting ► 24/7 Support ► 99.9% Uptime ► 60 Day Money Back Guarantee
■█► cPanel, Litespeed, CloudFlare, Softaculous, Attracta SEO, Site Builder
■█► Find us on Facebook and follow us @wirenineComment
widgetinstance 262 (Related Topics) skipped due to lack of content & hide_module_if_empty option.
Comment