% strip when wxlocal processed to wx

Hello
% strip when wxlocal processed to wx

I use a google page tracking code on my web site.
It has worked ok until I updated to version 10.37S4 from R300 versions
The pagers that are processed by weatherdisplay ie wxlocal to wx have the % striped from the page when processed to wx file
The line of code is:- document.write(unescape(“%3Cscript src='” + gaJsHost + “google-analytics.com/ga.js’ type=‘text/javascript’%3E%3C/script%3E”));
Has something changed that could course this?
Is there away wx could change from wx.html to wx.pnp file type? If so I can get round this problem.
Regards
Steve

Hi Steve,
My Google analytics code is saved in a separate file (google.js) on my the webserver and is called by

<script type="text/javascript" src="google.js"></script>

on any page that requires it.
so that would get around this issue.
Interestingly my Google code does not have any % in it. Google changes the code from time to time. The latest code is HTML5 compliant.
Martyn

I had already fixed though a bug where a lone % was removed in a more recent version

Brian
Have download version 10.37s6. Problem still present.
The line of code is:- document.write(unescape(“%3Cscript src='” + gaJsHost + “google-analytics.com/ga.js’ type=‘text/javascript’%3E%3C/script%3E”));
It has 4 % in the line.

Martyn
Have looked at the google tracking site & the code has changed.
Will try your suggestion on one page overnight & see what happens.

Thanks
Steve

of those 4 % signs, which one is stripped out?

Hi Brian

First 2 % were striped out, see below:-

From wxlocal.html
document.write(unescape(“%3Cscript src='” + gaJsHost + “google-analytics.com/ga.js’ type=‘text/javascript’%3E%3C/script%3E”));

From WX.html
document.write(unescape(“3Cscript src='” + gaJsHost + “google-analytics.com/ga.js’ type='text/javascript’3E%3C/script%3E”));

I will see if I can duplicate…and fix…

happens here too
I will see if I can fix and let you know

fixed this in the latest .zip update, ready now
(problem only occured if there was like more than 3 extra % in a line)

Tested latest version 10.37s6 & problem is fixed

Thanks for your support
Steve

you should find that the latest version processes custom tags faster than build 81

Hi Brian;

Latest ver 10.37S bld 6 with new % handling
wx5local.txt

<?php echo $humidity; ?>%  Rate: <?php echo $humchangelasthour; ?>% /hr

WD parsed line in wx5.php

<?php echo $humidity; %?>  Rate: <?php echo $humchangelasthour; ?>% /hr

The <?php echo $humidity; %?> is a real show stopper, causes page to not load with an error 500.

Work around was to eliminate one of the percent signs from the line (wasn’t real needed since column width was already set)
wx5local.txt

<?php echo $humidity; ?>%  Rate: <?php echo $humchangelasthour; ?>% /hr

WD parsed line in wx5.php

<?php echo $humidity; ?>%  Rate: <?php echo $humchangelasthour; ?>% /hr

All is good for me now, but I am posting this in case others encounter a too many % problem.

Gus
http://www.halethorpeweather.com/wx5.php

so WD is putting that second % in the wrong place?

Hi Brain,

To confirm the problem, I copied the line back into the wxlocal5.txt file and parsed and uploaded to my website. The page would not load with error 500.
wx5local.txt with three percent signs…

<?php echo $humidity; ?>%  Rate: <?php echo $humchangelasthour; ?>% /hr wx5.php as uploaded... <?php echo $humidity; ?%>  Rate: <?php echo $humchangelasthour; ?>% /hr

The second % has been “moved” from <?php echo $humidity; ?>%  to <?php echo $humidity; ?%> 

So, yes, WD is putting the 2nd % in the wrong place.

Like I said, I can get down to only two % in the line, so this is not a problem for me to work around.

Gus

I will see about duplicating and fixing

I have fixed this, in the latest .zip update

Hi Brian,
Downloaded the latest bld 6 zip file.
All three of the percent signs are now showing up in the correct places.
I also tested adding a fourth % and all was good.
Thanks,
Gus