Learn how to a build a cloud-first strategyRegister Now

x
?
Solved

change <form> attributes

Posted on 2011-10-07
6
Medium Priority
?
190 Views
Last Modified: 2012-06-27
http://jsfiddle.net/knowlton/f7z63/4/

How do I change the name attribute of my form?

HTML:
<form name="smith"></form>

jquery:

$('form').attr("name", "hoowah");   ////////////  DOES NOT WORK
0
Comment
Question by:Tom Knowlton
  • 3
  • 2
6 Comments
 
LVL 83

Accepted Solution

by:
leakim971 earned 1900 total points
ID: 36933591
0
 
LVL 5

Author Comment

by:Tom Knowlton
ID: 36933755
When I try this for my asp.net page --  and I do a "View Page Source" ...   the form name has not changed.  It still says:

<form name="aspnetForm" method="post" action="default.aspx" id="aspnetForm" style="background-color: #E1DFDB;">
0
 
LVL 83

Expert Comment

by:leakim971
ID: 36933766
use firefox or chrome, right click on the first field and choose << inspect element >>
else you just see the original content not the modified content
0
Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 13

Assisted Solution

by:haloexpertsexchange
haloexpertsexchange earned 100 total points
ID: 36933780
you are not going to see the changes with a normal view source.
To changes that javascript does you need to see the generated source.
I have firefox and something called web developer and when I right click to view source I can go to something called web developer->view source->generated source and that shows all changes that have happened because of javascript
0
 
LVL 5

Author Comment

by:Tom Knowlton
ID: 36933847
>>>use firefox or chrome, right click on the first field and choose << inspect element >>
else you just see the original content not the modified content
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~


Ahhh -- yes -- I see the change.

Thanks!
0
 
LVL 5

Author Closing Comment

by:Tom Knowlton
ID: 36933850
thx
0

Featured Post

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Hi all! Recently there was EE question and the person wanted to have a multi-column textbox <div> selection, so as a first step to answer I provided a link but that was not complete with JavaScript selection, but had a good style sheet. So as a ques…
I found this questions asking how to do this in many different forums, so I will describe here how to implement a solution using PHP and AJAX. The logical flow for the problem should be: Write an event handler for the first drop down box to get …
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…
Suggested Courses
Course of the Month21 days, 6 hours left to enroll

810 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question