I have a page I am working and I am having some trouble with: I need to show and hide areas based on a radio selection. I initally started using the show / hide feature in Jquery but the problem is the elements need to be removed but then put back if the user selects the radio buttonagain as it has form elements that have validaion on them. The validation is still trying to validate the form elements becuase they are still on the page but just not showing. This is the radio group the user makes the selection from:
I'm having an interesting IE6 and IE7 issue that may just be par for the course. i'm curious if anyone else has run into this problem.
Here's the URL: [url]
I have a bunch of nested lists with IDs in certain ULs, like <ul id="collapse">. i'm trying to use jQuery .hide() to hide all the ULs with that specific ID. everything works as expected in firefox, safari, chrome, IE8, etc. but IE6 and IE7 seem to only notice the first UL in the DOM tree. so IE6/7 hides that first UL, then stops.
i want to hide some elements on my site, but don't want to makethese inaccessible for users without javascript enabled. Some usersare complaining about being able to see that element for a splitsecond before the page has finished loading and the element is hidden.Is there a way in which I can hide the elements right from the start,
oving jQuery at the moment, and have sort of hit a hiccup with showing and hiding specific elements with the same class. My idea is, what if I wanted to add a little button to show and hide the contents of a specific comment on a forum post, or blog, whatever. This would be easily done with id's but I'd like to just apply a class to each one of them and allow them to hide their contents. Here is the javascript and html as an example of what I am talking about.
i've got a question. I would like to show childlists in a sidebar which have less than 2 elements in it, and hide childlists which have more 4 elements in it.this is what i got til now:
I am new to jQuery and I am having trouble with the syntax, selectors and refining when trying to create functions. What I am trying to achieve: I have a gallery consisting of a ul with images placed in vertically stacked list items. The ul is in a fixed size wrapper with overflow:hidden so only the first list item displays. The user clicks a button and the first li is hidden using hide(400). This makes the other list items flow up and reveals the second list item within the wrapper window.
When the last list item is visible, the click will show(400) all of the list items again, causing them to flow back into order and only the first item will be showing again. Further clicks will repeat this process from the beginning. I know what I would like to do in terms of code, but I am having trouble with the correct syntax, selectors and refining. I have included the html and description version of the code I was hoping to create. I know the code could be much more efficient by placing functions into variables and testing for true false, but I would like to see the steps with my longer code description for learning purposes. Perhaps afterwards someone can blast it off in two lines.
how one can show and hide a div element using a pulldown menu. i need the different selections in the pulldown menu to show hidden DIV elements on the page. this will be used in a system where i only have access to the template, so the only approach i can use is jquery. how to change it for the specific selectors i need.
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head>
I am trying to hide/show table when hide/show button is pressed
Problem: The code works fine when I remove 'slow' from line 10. But with 'slow' in line 10 content of toggleButton doesnt change from Hide to Show when pressed.
I'm using jQuery 1.4 to hide a div (#cartPop) when the "close" link inside of it (#cartPop a) is clicked. Since I'm using animate() to fade the div out (opacity), I also have to use hide() to get rid of the div once it has faded out (otherwise the invisible div, which is on a higher z-index, blocks the elements on a lower z-index).
Code:
The problem is that the hide() function calls immediately without waiting for the animate() function to run. Even if I append a delay() function before hide() like so:
And a corresponding text_field input element div I'd like to display based on which radio button the user selects:
When the page loads, I'd like to see:
When the user clicks on a (different) radio button, or clicks one for the first time, I'd like whichever div is currently showing to be hidden, and the newly selected one to be shown.
Right now I have jQuery code at the bottom of my page that looks like this:
For each of the four options.
When the page loads, the correct div is shown, and when I select a new button, the new div is shown, but the already showing one isn't hidden.
I've read some posts that suggest using change() instead of click(), but others indicate that's problematic in IE.
I have a dynamically generated page (PHP), which contains an Explorer like view of items. I would like to hide multiple <tr>'s by name, but I can't figure out how thats done.
I have this code to hide one element by id
if (document.getElementById(id)){ document.getElementById(id).style.position = 'relative' document.getElementById(id).style.display = 'none' }
Anyone has a cod sample for looping through multiple elements and hide them?
I have some nested lists that I am trying to clean up. What I am wanting to do is to be able to click an item in the outermost list (the catagory), and have it show the appropriate inner list (the subcatagory). I have it working in FireFox, but IE is not working. Code:
I'm working on a form that hides/shows certain elements when certain things are selected.
In the file I'm working with, when you select the "problem" radio button, the "problem" drop down menu appears. When you select the "request" radio button, the "request" drop down menu appears
Now, when I try to make a selection from the "problem" drop down menu, nothing appears like it should (Computer, Monitor, Printer, and AVPeriph are the active ones). Everything stays hidden.
With each of those 4 selections, a table element should appear. Any ideas to what the problem is? I'm assuming it's the javascript since I don't know it too well.
I have a page which consists of mutiple DIV's which each of them have an ID in the following naming convention:
box_1 box_2 box_3
[code]....
if a user clicks a box to remove it from the screen (e.g. they click box_2) I need box_3, box_4 and box_5 to be hidden as the process on screen is linear - i.e. the user should only be able to see the next box when they make a selection from the current box.Is there any way I can hide these boxes if the box previous to them is removed?I have seen something for jQuery gt() but I tried using it as below but nothing happened:
I'm trying to figure out a small javascript question. I have certain elements in my pages that I want to show or hide if the user has javascript disabled. [code]...
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 a page that is generated using php. Below, the pdf newsletter for each month is embedded directly into the page. What I want to do is have some javascript that when the link for a month is clicked, the embedded pdf expands below and when the user clicks on another month, that newsletter is hidden then the one they clicked on gets displayed; so only one newsletter is displayed at a time.
I've got a need to hide a function from ie6 (long story). Does anyone know how I can target that browser and stop the rest of the script from processing?
I looked at using jQuery.support but am not able to find a test that returns false for ie6 only . I want to wrap my function in some type of conditional that stops ie6 in it's tracks but all other browsers can process. Something like this:
I'm building a website, and use your framework to hide/show a div. This work, but in IE when click to hide/show the div, the background became black, instead to maintaine the image with alpha properties. In Firefox, Opera and Chrome works fine.