[jQuery] Re: jQuery and swapping name values

2008-09-09 Thread Velcrobelly
Anyone? On Sep 8, 5:01 pm, Velcrobelly [EMAIL PROTECTED] wrote: I am using the following to do a Hide/Show feature, and it works exactly as I want... --snip- script type=text/javascript $(function(){         $('#sender').click(function(){                         $('#container

[jQuery] Re: jQuery and swapping name values

2008-09-09 Thread tlob
Can you be more specific? I dont get it Sorry You fill out the first Input, save the form via a submit button and then? But now I need to be able to swap the name values of the text fields on the toggle as well, so that the visible text field always carries the name value of data01.

[jQuery] Re: jQuery and swapping name values

2008-09-09 Thread mbraybrook
You may have to replace slideToggle with a conditional .hide() .show() and some other information. Pseudo-code: .: Check the state of the two divs seperately, perhaps by providing unique ID's for each one? .: If one is hidden, show it and set the name attribute to data01 .: if one is shown, hide

[jQuery] Re: jQuery and swapping name values

2008-09-09 Thread Velcrobelly
I am doing this for a custom layout that I can only upload basic HTML/ JavaScript to. When the page is rendered, the server unfortunately strips 'non- allowed' ID settings from the tags. Is it possible to do without setting ID values in the input tags? - VB On Sep 9, 8:14 am, mbraybrook

[jQuery] Re: jQuery and swapping name values

2008-09-09 Thread Velcrobelly
I will try to be clearer... The checkbox controls the hide/show toggle of the two divs. Initially, the first div is visible and the name value for the input field in it is 'data01'. The second div is hidden and the name value of the input field in it is 'data02'. When the checkbox is clicked

[jQuery] Re: jQuery and swapping name values

2008-09-09 Thread mbraybrook
Hmm, a quandry, I'll do a little testing for you and get back when/if I can, unless someone else can provide an answer in the mean time. Regards Mark On Sep 9, 3:10 pm, Velcrobelly [EMAIL PROTECTED] wrote: I will try to be clearer... The checkbox controls the hide/show toggle of the two