[Greasemonkey] Making a script compatible with GM 0.5.3 and GM 0.6.4

Aaron Boodman zboogs at gmail.com
Sun Dec 4 14:24:37 EST 2005


unsafeWindow existed in 0.5.3, so you can use it in both places.

- a

On 12/1/05, Blake West <blakewest at gmail.com> wrote:
> If I need to change the values of some variables declared on the target
> website, do I just need to do something like the following to make a script
> compatible with GM 0.6.4 and 0.5.3?
>
> if(unsafeWindow){
>     w = unsafeWindow;
> }
> else{
>     w = window;
> }
>
> w.variableToBeChanged = newValue;
>
> Thanks,
> --
> Blake
> _______________________________________________
> Greasemonkey mailing list
> Greasemonkey at mozdev.org
> http://mozdev.org/mailman/listinfo/greasemonkey
>


More information about the Greasemonkey mailing list