I am working on debugging a site that I inherited from another developer. One of the issues is that the OpenLayers map was broken in Internet Explorer 8. When loading, the browser would display the following message:
Message: Arg: Fraction out of range (0 to 1 allowed)
Line: 2597
Char: 1
Code: 0
URI: http://openlayers.org/api/2.11/OpenLayers.js
After a while, I discovered that someone had set the fillOpacity in the style properties of a style to 2, despite the fact that the help text clearly states that "This should be a value between 0 and 1."
Perhaps we might add a validate function to ensure that this value is being set properly when the form is being filled out, or check that it is not greater than 1 when creating the map?
Comment | File | Size | Author |
---|---|---|---|
#7 | 1719598.patch | 1.13 KB | Pol |
#6 | 1719598.patch | 1.13 KB | Pol |
#4 | 1719598.patch | 1.09 KB | Pol |
#2 | 1719598.patch | 12.96 KB | Pol |
Comments
Comment #1
PolI take care of this.
Comment #2
PolFirst shot of the patch.
Comment #4
PolComment #6
PolComment #7
PolI made the patch without testing, if someone can test it, I can commit it tonight.
Comment #8
PolCommitted ! Thanks for the report !
I did not used the patch I made, I used the #element_validate property for elements in the form.
http://drupalcode.org/project/openlayers.git/commitdiff/f15b420?hp=48a73...