Issues

ZF-8720: Bug fix for setLocation with exclamation mark

Description

Zend Framework 1.9.6 (r19198). Released on November 23, 2009.

Package Zend_Gdata > YouTube File: Zend\Gdata\YouTube\VideoQuery.php

Bug: Line:143 //$temp = substr($temp, -1);

Fix: Line:143 Replace with... $temp = substr($temp, 0, strlen($temp)-1);


Explaination: http://code.google.com/apis/youtube/… To exclude videos from the API response if those videos are associated with a descriptive address but not with specific geographic coordinates, append an exclamation point ("!") to the end of the parameter value. This practice effectively ensures that all videos in the API response can be plotted on a map.

The following examples show sample uses of this parameter: location=37.42307,-122.08427&location-radius=100km location=37.42307,-122.08427!&location-radius=100km


The variable $temp is to temporary remove the exclamation (!) so that the longitude can validate as numeric. However, substr($temp, -1); will return the substr (!) instead of the expected (-122.08427). To fix this, we simply need to change that to substr($temp, 0, strlen($temp)-1)

Comments

What is the problem? Can you specify the problem or bug with some lines of example code?

fixed with r20097

Marco, Thanks for quickly fixing this.

However, I don't see a commit into a release branch. Are you sure this is fixed for the next mini release?

Yes i'm sure because i commited all to the right branch. I looks like the Fisheye is a bit out of sync. :)

Oh Fisheye. Always causing trouble. ;)

Thanks again!