tags:

views:

36

answers:

1

Would it be possible with jQuery to find in all symbols that are written with

®

and wrap them with a sup tag?

<sup>&reg;</sup>
A: 
var replaced = $('body').html().replace('&reg;', '<sup>&reg;</sup>');
$('body').html(replaced);
Jacob Relkin
Of course, using `html` will remove all `.data` and attached event handlers, so it is better to do it on elements that contain only text.
Kobi