[jQuery] Re: Get some text and replace it

2008-06-20 Thread Ischa Gast
You are my hero! Now I have this little email encrypter: // This is to prevent two searches var email = $('span.email'); email.html( email.html().replace(' [monkeytail] ', '@').replace(' [dot] ', '.') ).wrapInner(''); What I had was this: createEmailAddress();

[jQuery] Re: Get some text and replace it

2008-06-19 Thread Isaak Malik
Oh sorry, the code I gave you just modifies the loaded HTML and doesn't write it back so this should work for you: // This is to prevent two searches var email = $('span.email'); email.html( email.html().replace('[monkeytail]', '@') ); Enjoy On Thu, Jun 19, 2008 at 8:33 PM, IschaGast <[EMAIL P

[jQuery] Re: Get some text and replace it

2008-06-19 Thread IschaGast
> $('span.email').html().replace('[monkeytail]', '@'); I was also thinking it should be something like this, but this doesn't work... This should be possible some way I hope. > And you probably also need: > > $('span.email').html().replace('[dot]', '.'); > > On Thu, Jun 19, 2008 at 12:26 AM, Isc

[jQuery] Re: Get some text and replace it

2008-06-19 Thread Isaak Malik
You could do it with: $('span.email').html().replace('[monkeytail]', '@'); And you probably also need: $('span.email').html().replace('[dot]', '.'); On Thu, Jun 19, 2008 at 12:26 AM, IschaGast <[EMAIL PROTECTED]> wrote: > > I have this: contact [monkeytail] yabadabadoo > [dot] .com > Now I wan