On Jan 12, 7:17 am, chris idr <[email protected]> wrote:
> Hi all,
>
> can anyone tell me if rhino properly supports the replace function in
> javascript, as i have an example and it doesn't seem to.
>
> all it seems to do is redirect the call to java replace.
>
> i have a replace(/,/gi,";");  (the g means replace all and the i means
> ignore case)
>
> can anyone tell me how to make this work properly, or when it might be
> added.
>
> if its not going to be added anytime soon, then could someone be kind
> enough to tell me what to change in rhino itself so i can get it to
> work, and i will submit my fix to you for inspection
>
> regards
> chris wade

The replace function is completely implemented as far as I know:

js> var s = "Hi, Mom";
js> s.replace(/m/gi, 'b');
Hi, bob

What isn't working for you?

--Norris
_______________________________________________
dev-tech-js-engine-rhino mailing list
[email protected]
https://lists.mozilla.org/listinfo/dev-tech-js-engine-rhino

Reply via email to