I'm making a page with no hide / show and have thrown me over Jquery. When you press a picture, it make a box underneath. It works fine, but there must be more pictures and will ONLY be the box under the image is pressed to display and not all the div boxes. Have tried with next () and it cares not quite for me.
in my page i have two nav bars, one for js enabled and one for js disabled they are styled accordingly (the js disabled is display:inherit; and the js enabled is display:none;)now i may need to tweak those styles after i get the script working, but that i can toy with after i get this working anyways- my pages get the navbar inherited from a master page- so my thought was (to prevent loops) make a nav bar that had all js disabled links and a navbar that had all js enabled.
I have a HTML document with form. The form has several radio buttons. I want different elements of HTML (including <input> elements) to appear when each radio button is selected. Also, it is intended to show only those elements for a specific radio button. For example, if i select RB1, it shows me element div 1 and hides all others. If i select RB2, it hides element div 1 and shows element div 2, et cetera. So far it works fine with .style.visibility = 'hidden' and 'block'. Now, here comes the problem - each element appears below the previous element, they appear as they are in the HTML, no matter if i show the previous one. It looks pretty bad, because element positions are jumping as i select different radio buttons. How do i keep them in the same level, at the same position?
I have found and addapted a script that displays or hides a div tag based on it's current class tag, but i can't seem to get it to work. I am new to Java, and i know that everything has to be perfect in order for it to function.
Would it be possible for someone to check over my script and point out any errors there may be/extra spaces etc?
I've been messing around and searching about trying to find something which will only allow one of the hidden div's open at a time. When a new link is clicked, the last div open closes. Unfortuanatly I haven't found anything yet.
To build a menu block which should be switchable with hide/unhide of the menu items, I'm using .append html. The code idea is this:
As can be seen from above posted code there is a line "<div id="' + menuSlider + '" style="display:none">". Appending that -- AFAIS -- the .append is automatically (????) adding "</div>" which closes the statement. That breaks my idea of the whole concept! The menu part isn't included in the 'menuSlider '. QQ: How to change it -- NOT to have that "</div" added to it??
Im trying to add some simple display features to a web application and am running into some unexpected IE8 behavior. Basically, the app runs some database retrieval from the server using Ajax techniques, and during that time (say, 30 seconds), I want to just give the user a clue as to whats going on. It could be as simple as a wait cursor. More interesting, I prefer to unhide a div with an animated loading icon, then hide it again when loading is complete.
I am able to append html <a> tags inside a div. I added 60px to each <a> tag created except for the first <a> tag which has 0px. These px's I added are in the css value of top. That's way each <a> tag will be appended downwards. Now I made with these <a> tags a checkbox input tag. they are named all the same name but pass different values. When you click the checkboxes and hit my delete button... it removes the checkboxes that were selected and the <a> tag that was selected to be deleted. all checked will be deleted when the delete button is pressed. That's all neat and dandy... but the problem comes when for example lets say I got 6 rows of <a> tags with check boxes.
Lets say 2 and 4 got selected and deleted... well wherever their position was it's now blank. I want to make number 3 to move back one position. have 5 move 2 times. So 5 takes number 3's place. and 6 will move 2 times. it will move to take 4's place. So now 6 won't be called 6 anymore now it be 4 , 5 would be 3 . then 3 would be 2. 6 minus 2 equals 4 so that be how it should replace the deleted <a> tags spaces. I would want to rename those. What I am doing is I have a checkout page. This is where customers can add orders in to a list so they can buy more then 1 stuff at the same time or at one transaction.
I just want them if they added too many items or made mistakes they can easily delete them from the list. Now I added 60px to the css top value... but since we are going in reverse then here comes the tricky part. Lets go back to my example where we deleted 2 and 4 out of a total of 6 numbers. Any number beyond 2 and 4 will get their css values subtracted by 60px 2 times so it be a loop and that css value would be the top value. Now any number after 2 but not after 4 then I would subtract 60px for only 1 time. which I still need to loop this. It looks like I need a loop based on total numbers that be 6 in our example. So I would have 6 and every loop completed it would subtract 6 by 1.
Inside the loop. I would need to check the ones not deleted to what they stand based on the total numbers and if they are greater then the two numbers. The problem is that I would need o generate if statements because that be based on how many were selected to be deleted. So this would vary. In our case we would check if 6 is greater then 2 and 4 and if so then loop the increase in pixes 2 times so we subtract 60px 2 times. then we then look at each number and test them. If they are not behind 2 or 4 then don't do anything to them but if they are behind 2 then we will loop to subtract 60px's one time.
The problem is that when I delete the <a> tags there is a missing gap displayed... I want it that my list adjusts so no matter how many are delete and if they are not in order... the they are deleted the <a> tags still should be able to adjust or readjust so the list is in order once again. So the example above we eliminated numbers 5 and 6 we deleted 2 and 4 so 3 took 2's place , 5 took 3's place and 6 took 4's place and 6 got renamed to 4 , 5 renamed to 3 and 3 renamed to 2. so 5 and 6 no longer exist. In my real code these numbers be items listed. just a number to associate their reference in the list.
i have to hide/unhide some fields on basis of some other fields. i found this script on the web.i can't understand the function completely what is the if ( txt.match(id1) ) block doing ?? is there any other way of doing the same...
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <head> <meta http-equiv="Content-type" content="text/html; charset=utf-8" />
I would like to hide/show the relevant divs (into a container) based upon the button pressed. If no div was open, then it would simply open the relevant div, however if say div 2 was open and div 3 was pressed, div 2 would toggle closed then div 3 would toggle open.
I've got each individual div opening and closing, but I'm stuck at the next point (checking if a div is open/toggling etc).
I want to modify the appearance of an unordered list by assigning a value to each list item and then setting the custom properties for each list item. At first I was thinking of assigning a number to each list item and then controlling it's properties via that number.But now I'm wondering if jQuery can do a search for the list items content.
Does anyone know why this isn't working? The toggle function works perfectly fine with PHP loops, but when I insert the table td tr tags, it does not hide the loop when the page first loads...It just shows the results in the div which it shouldn't be doing.
Here's what my code looks like...