473,378 Members | 1,377 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,378 software developers and data experts.

Problem, need help.

I have found this nice menu form my website www.folkspot.be
But it has a usability problem.
When i click "crew" for example, the submenu "crew" opens and i have to
click the submenu to get to the page. As you notice, this is a click to
many. As you can see this is the case in several items. Some do have
subitems and work fine. I'm to much of a newbee in javascript to figure
this out.

Can someone please help me fix this problem?

thanks.

--
Bigbuddha
www.bigbuddha.be
www.folkspot.be

Jul 20 '05 #1
2 1197
Open the SLIDING_MENU.JS file and look for the function
"write_menu()". Scroll down until you see the variable "csmc = 0;".
The next line should be a command starting out like this:

document.write("<div class='men' style='top.....
Highlight and COPY the code below. Find that
"document.write("<div......");" command as stated above and copy over
the ENTIRE line with the new code.
//START YOUR COPY HERE
if (la[2] != "")
{
document.write("<a href='"+la[2]+"'
style='text-decoration:none;'");
if (la[3] != "") document.write(" target='" + la[3] + "' ");
}

document.write("<div class='menu'
style='top:"+mn+";height:"+height+"' id='down"+smc+"'
onclick='prepare("+smc+","+mni+")'>&nbsp;"+ la[1] + "</div>");

if (la[2] != "") { document.write("</a>"); }
//END YOUR COPY HERE

You're done!!! All this does is wrap that main menu item with a <A>
tag IF you add a link in your LINK array. Here are your new choices
when adding a link. Choice 3 is what you wanted....

//MAIN MENU ITEM - SUB-MENU LINK.
Link[0] = "0|Home|";
Link[1] = "1|Home|index.html|_top";

//MAIN MENU ITEM - NO LINK
Link[0] = "0|Home|";

//MAIN MENU ITEM - LINKED WITHOUT SUB-MENU
Link[0] = "0|Home|home.html|_top";
Jul 20 '05 #2
BigRed wrote:
Open the SLIDING_MENU.JS file and look for the function
"write_menu()". Scroll down until you see the variable "csmc = 0;".
The next line should be a command starting out like this:

document.write("<div class='men' style='top.....
Highlight and COPY the code below. Find that
"document.write("<div......");" command as stated above and copy over
the ENTIRE line with the new code.
//START YOUR COPY HERE
if (la[2] != "")
{
document.write("<a href='"+la[2]+"'
style='text-decoration:none;'");
if (la[3] != "") document.write(" target='" + la[3] + "' ");
}

document.write("<div class='menu'
style='top:"+mn+";height:"+height+"' id='down"+smc+"'
onclick='prepare("+smc+","+mni+")'>&nbsp;"+ la[1] + "</div>");

if (la[2] != "") { document.write("</a>"); }
//END YOUR COPY HERE

You're done!!! All this does is wrap that main menu item with a <A>
tag IF you add a link in your LINK array. Here are your new choices
when adding a link. Choice 3 is what you wanted....

//MAIN MENU ITEM - SUB-MENU LINK.
Link[0] = "0|Home|";
Link[1] = "1|Home|index.html|_top";

//MAIN MENU ITEM - NO LINK
Link[0] = "0|Home|";

//MAIN MENU ITEM - LINKED WITHOUT SUB-MENU
Link[0] = "0|Home|home.html|_top";


I'll give it a try tonight

thansk!

--
Bigbuddha
www.bigbuddha.be

Jul 20 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

11
by: Kostatus | last post by:
I have a virtual function in a base class, which is then overwritten by a function of the same name in a publically derived class. When I call the function using a pointer to the derived class...
6
by: Pierre-Benoit | last post by:
Hi there, I've a strange problem with ado.net and an Access db. I need to create a little C# app that take the content of "ole object" field and then save it into a file. The problem is that...
16
by: cody | last post by:
I have to write an algorithm with must ensure that objects are put in buckets (which are always 4 in size). The objects have two properties: A and B. It is not allowed that in a bucket are objects...
4
by: Leslaw Bieniasz | last post by:
Cracow, 20.09.2004 Hello, I need to implement a library containing a hierarchy of classes together with some binary operations on objects. To fix attention, let me assume that it is a...
7
by: Amar | last post by:
I am trying to connect to my college LDAP directory using ASP.NET. This LDap does not have security as it returns only user demographic information. i do not need to bind with a username or...
28
by: Jon Davis | last post by:
If I have a class with a virtual method, and a child class that overrides the virtual method, and then I create an instance of the child class AS A base class... BaseClass bc = new ChildClass();...
5
by: Vishal | last post by:
Hello, I already asked this question in the ASP.NET forums, but no help came. So I am hoping that somebody can help me out. This is really very URGENT me. For my e-commerce application, I...
6
by: TPJ | last post by:
Help me please, because I really don't get it. I think it's some stupid mistake I make, but I just can't find it. I have been thinking about it for three days so far and I still haven't found any...
6
by: =?iso-8859-1?B?QW5kcuk=?= | last post by:
I've encountered a problem using gettext with properties while using a Python interpreter. Here's a simple program that illustrate the problem. ============== # i18n_test.py: test of gettext &...
9
by: AceKnocks | last post by:
I am working on a framework design problem in which I have to design a C++ based framework capable of solving three puzzles for now but actually it should work with a general puzzle of any kind and I...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.