03-06-2004, 09:40 AM -
In the following code fragment from a provider file I'm writing, I've found a potential problem with fetching temperatures.
Here's the HTML I'm parsing:
Parsing this returns 0°C, but if I remove the Unit = C line from the provider file, I get 3 returned.
I've tried a delim = "°" just in case that was the cause, but I still get 0°C!
Code:
; Dewpoint
; -------------------------------------------------------------------------
[CustomParam4]
name = Dewpoint
unit = C
find0 = "<!-- CURRENT REPORT TABLE -->"
find1 = "<!--Temp-->"
find2 = "Dewpoint:"
delim = "<"
Here's the HTML I'm parsing:
Code:
Dewpoint: 3 °C<br />
Parsing this returns 0°C, but if I remove the Unit = C line from the provider file, I get 3 returned.
I've tried a delim = "°" just in case that was the cause, but I still get 0°C!