On 2/1/07, Christophe Porteneuve <[EMAIL PROTECTED]> wrote: > Note that this regex is altogether different. The former one isolates > the contents of every script tag in your text, while yours takes > everything between the *first* opening script tag and the *last* closing > one. If you take an XHTML fragment with multiple script tags (which > happens quite often), your regex will just fail miserably. good point. I put back your first regex to take care of multiple <script> tags.
> Also, the '(\n|\r|.)' instead of '.' is there because '.' is not > supposed to be multi-line. Does your regex (or even mine) work on > script fragments spanning multiple lines? Alas, mine does not span lines. Yours does. However I am faced with Safari crashing on the original reg ex. I haven't tried updating my webkit yet and i'm not sure it's reasonable to tell our users to update webkit to use our website. I'll have to think it over but making sure the js code is all on one line is easier in this circumstance. If you have any suggestions, I'd love to hear them. Cheers, Randy -- Imagine no possessions I wonder if you can No need for greed or hunger A brotherhood of man Imagine all the people Sharing all the world --John Lennon --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Spinoffs" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-spinoffs?hl=en -~----------~----~----~----~------~----~------~--~---
