Issues

ZF-8720: Bug fix for setLocation with exclamation mark

Issue Type: Bug Created: 2010-01-05T22:48:11.000+0000 Last Updated: 2010-01-07T08:27:30.000+0000 Status: Resolved Fix version(s): - 1.9.7 (11/Jan/10)

Reporter: Peng Kong (pengkong) Assignee: Marco Kaiser (bate) Tags: - Zend_Gdata

Related issues: Attachments:

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

Posted by Marco Kaiser (bate) on 2010-01-06T02:09:33.000+0000

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

Posted by Marco Kaiser (bate) on 2010-01-06T07:45:45.000+0000

fixed with r20097

Posted by Trevor Johns (tjohns) on 2010-01-06T11:12:00.000+0000

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?

Posted by Marco Kaiser (bate) on 2010-01-07T01:39:16.000+0000

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

Posted by Trevor Johns (tjohns) on 2010-01-07T08:27:30.000+0000

Oh Fisheye. Always causing trouble. ;)

Thanks again!

Have you found an issue?

See the Overview section for more details.

Copyright

© 2006-2016 by Zend, a Rogue Wave Company. Made with by awesome contributors.

This website is built using zend-expressive and it runs on PHP 7.

Contacts