![]() |
|
![]() |
|
|
Thread Tools | Display Modes |
|
|
|
|
#1 |
|
Newbie
Join Date: Oct 2006
Posts: 4
Rep Power: 0
![]() |
dropdown menu location problems
So I'm using someone else's script for the dropdown menus I'm using on my site, but it's making the menus drop down in the wrong place... I don't know much (read: anything) about java, but I was able to decipher it to the point that I think is the problem:
showhide(dropmenuobj.style, e, "visible", "hidden") dropmenuobj.x=getposOffset(obj, "left") dropmenuobj.y=getposOffset(obj, "top") dropmenuobj.style.left=dropmenuobj.x-clearbrowseredge(obj, "rightedge")+"px" dropmenuobj.style.top=dropmenuobj.y-clearbrowseredge(obj, "bottomedge")+obj.offsetHeight+"px" The menus now drop down 2/3 of the way down the screen and 2/3 of the way across. I've had one person (who also knows nothing about javascript) say that it might have something to do with centering issues, which would be at the html level. http://www.geocities.com/boyscouttroop49/index2.html Yes, I know geocities is bad. Yes, it's getting a real domain. Probably as soon as I finish this. Any help is much appreciated. |
|
|
|
|
|
#2 |
|
Resident Grouch
![]() ![]() ![]() ![]() ![]() ![]() Join Date: Jun 2005
Posts: 6,453
Rep Power: 10
![]() |
"obj" isn't what you think it is, apparently. You don't show enough for us to tell. I don't imagine many people will be willing to dig behind your screen and fetch the code, but that's just opinion. You can make nice menus without resorting to Javascript and you can do most anything you like without frames. Personally, I'd suggest that you hit a few tutorials, or if web design isn't going to be your thing, hire a pro.
__________________
Abstraction doesn't make it impossible to write bad code; it makes it possible to write superior code. Contributor's Corner: Grumpy on C++ Exceptions DaWei on Pointers |
|
|
|
|
|
#3 |
|
Newbie
Join Date: Oct 2006
Posts: 4
Rep Power: 0
![]() |
Wait, where did frames come into this?
Anyway, I figured it out. It was more of a css problem anyway to do with centering and a rogue position:relative tag. I'm using JS because it gives exactly the format I want, and, barring any other mistakes I make, works fairly simply. Working Version |
|
|
|
|
|
#4 |
|
Resident Grouch
![]() ![]() ![]() ![]() ![]() ![]() Join Date: Jun 2005
Posts: 6,453
Rep Power: 10
![]() |
I'm not denigrating Javascript. I use it for asynchronous xml/http requests, and I use it if I have to hack to make IE work properly. My point is that a lot of serious viewers will have Javascript disabled. The fewer things that scuttles (such as all-important drop-down navigation), the better. You might consider two versions.
I apologize for the frame statement, if it offended you. The frame is actually Geocities', a situation over which you have no control.
__________________
Abstraction doesn't make it impossible to write bad code; it makes it possible to write superior code. Contributor's Corner: Grumpy on C++ Exceptions DaWei on Pointers |
|
|
|
|
|
#5 |
|
Newbie
Join Date: Oct 2006
Posts: 4
Rep Power: 0
![]() |
Oh, okay. [frames thing] Sorry about that, I've learned very well how bad frames are (very openly opinionated teacher), so the idea scared me. ;]
Well, the site is for people who all (all=99.8%) end up being technologically incompetent, so the only thing I'm worried about is IE doing something drastic and ruining the whole idea, since I'm the only potential viewer not using it. Oh well, if I ever go into this business I guess I'll have to get used to it. :p And now for something completely different: You seem to be big with C++; I've been wanting to learn C/C++ for a while, but I'm not sure where to start. Any good tutorials pop into mind or would it be worth it to take a class? |
|
|
|
|
|
#6 |
|
Resident Grouch
![]() ![]() ![]() ![]() ![]() ![]() Join Date: Jun 2005
Posts: 6,453
Rep Power: 10
![]() |
There are a zillion recommendations in the tutorials area. Better check 'em out and make sure you like it (and invest in a good book or three) before you saddle yourself with a class.
__________________
Abstraction doesn't make it impossible to write bad code; it makes it possible to write superior code. Contributor's Corner: Grumpy on C++ Exceptions DaWei on Pointers |
|
|
|
|
|
#7 |
|
Newbie
Join Date: Oct 2006
Posts: 4
Rep Power: 0
![]() |
Well, I'm in high school and doing this problem called Running Start, so I can take classes at the local community college for free, and I think I have a free period next quarter, but yeah, it might be a good idea to make sure I don't hate it first. ;]
|
|
|
|
![]() |
| Bookmarks |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Java Popup Menu | titaniumdecoy | Java | 7 | Mar 12th, 2006 11:17 AM |
| dropdown menu with persistence? | kerriganm | HTML / XHTML / CSS | 11 | Dec 17th, 2005 2:33 PM |
| Need help with a realtime branching menu | Zeteg | JavaScript and Client-Side Browser Scripting | 11 | Aug 27th, 2005 11:36 AM |
| Help! I have a problem | thomas55 | C++ | 1 | Apr 24th, 2005 1:16 PM |
| airport Log program using 3D linked List : problem reading from file | gemini_shooter | C++ | 0 | Mar 2nd, 2005 4:12 PM |