Solved

Get rid of red asterisks

Posted on 2011-09-19
5
285 Views
Last Modified: 2012-08-13
I want to change this:

<font color="red">*</font>

to this:

<font></font>

using jQuery.


Thank you,

Tom

0
Comment
Question by:knowlton
  • 3
5 Comments
 
LVL 40

Assisted Solution

by:gurvinder372
gurvinder372 earned 100 total points
ID: 36561244
$("font[color='red']").html("");
0
 
LVL 82

Expert Comment

by:leakim971
ID: 36561252
please note : http://www.w3schools.com/TAGS/tag_font.asp
The font element is deprecated.

you may use : $("font:contains('*')").replaceWith("<font />");
test page : http://jsfiddle.net/udxDD/
0
 
LVL 82

Accepted Solution

by:
leakim971 earned 400 total points
ID: 36561262
with the red color : $("font:contains('*'):[color='red']").replaceWith("<font />");
test page : http://jsfiddle.net/udxDD/1/
0
 
LVL 5

Author Closing Comment

by:knowlton
ID: 36561519
thx
0
 
LVL 82

Expert Comment

by:leakim971
ID: 36561533
please note you don't need the colon before [color : $("font:contains('*')[color='red']").replaceWith("<font />");
http://jsfiddle.net/udxDD/2/
0

Featured Post

DevOps Toolchain Recommendations

Read this Gartner Research Note and discover how your IT organization can automate and optimize DevOps processes using a toolchain architecture.

Question has a verified solution.

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

Suggested Solutions

Introduction A frequently asked question goes something like this:  "I am running a long process in the background and I want to alert my client when the process finishes.  How can I send a message to the browser?"  Unfortunately, the short answer …
Introduction Knockoutjs (Knockout) is a JavaScript framework (Model View ViewModel or MVVM framework).   The main ideology behind Knockout is to control from JavaScript how a page looks whilst creating an engaging user experience in the least …
The viewer will learn how to dynamically set the form action using jQuery.
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…

911 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

Need Help in Real-Time?

Connect with top rated Experts

20 Experts available now in Live!

Get 1:1 Help Now