Skip to content

Commit 48818b6

Browse files
committed
fixed Url query decode
1 parent 890db87 commit 48818b6

File tree

2 files changed

+3
-4
lines changed

2 files changed

+3
-4
lines changed

src/Url.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -340,9 +340,9 @@ protected function parseUrl($url)
340340
if (isset($this->info['query'])) {
341341
parse_str($this->info['query'], $this->info['query']);
342342

343-
foreach ($this->info['query'] as &$value) {
343+
array_walk_recursive($this->info['query'], function (&$value, $key) {
344344
$value = urldecode($value);
345-
}
345+
});
346346
}
347347

348348
if (isset($this->info['path'])) {

tests/KewegoTest.php

+1-2
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,7 @@ public function testOne()
77

88
$this->assertEquals($info->title, 'Una gaviota traviesa roba una cámara mientras graba');
99
$this->assertEquals($info->description, 'Divertido vídeo en el que una gaviota se hace con una cámara mientras está grabando.');
10-
$this->assertEquals($info->imageWidth, 400);
11-
$this->assertEquals($info->imageHeight, 300);
10+
$this->assertEquals($info->code, '<object id="iLyROoaf2vuS" type="application/x-shockwave-flash" data="http://sa.kewego.com/swf/p3/epix.swf" width="400" height="300"> <param name="flashVars" value="language_code=es&playerKey=5e3d22b8b739&skinKey=&sig=iLyROoaf2vuS&autostart=false&advertise=1" /> <param name="movie" value="http://sa.kewego.com/swf/p3/epix.swf" /> <param name="allowFullScreen" value="true" /> <param name="allowscriptaccess" value="always" /> <param name="wmode" value="Opaque" /><video poster="" height="300" width="400" preload="none" controls="controls"></video><script src="http://sa.kewego.com/embed/assets/kplayer-standalone.js"></script><script defer="defer">kitd.html5loader("flash_epix_iLyROoaf2vuS","http://api.kewego.com/video/getHTML5Thumbnail/?playerKey=5e3d22b8b739&sig=iLyROoaf2vuS");</script></object>');
1211
$this->assertEquals($info->type, 'video');
1312
$this->assertEquals($info->authorName, 'zoomines');
1413
$this->assertEquals($info->providerName, 'kewego');

0 commit comments

Comments
 (0)