Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Loading…

Update toString() to use late static binding for encoding methods #3960

Merged
merged 1 commit into from

3 participants

@jvandemo

Updated the toString() method in \Zend\Uri\Uri so it uses late static binding to call the encoding methods.

Replaced self:: calls with static:: calls in toString().

This resolves problems when writing your own custom Uri classes.

Change-Id: I470379b8527852d5f36145c88ab05cbb51582103

Jurgen Van de Moere Update toString() to use late static binding for encoding methods
Change-Id: I470379b8527852d5f36145c88ab05cbb51582103
e9f45f1
@ezimuel ezimuel was assigned
@weierophinney weierophinney referenced this pull request from a commit
@weierophinney weierophinney Merge branch 'hotfix/3960'
Clse #3960
5d1efb6
@weierophinney weierophinney merged commit e9f45f1 into zendframework:master

1 check failed

Details default The Travis build failed
@ghost Unknown referenced this pull request from a commit
@weierophinney weierophinney Merge branch 'hotfix/3960'
Clse #3960
485d47c
@ghost Unknown referenced this pull request from a commit
@weierophinney weierophinney Merge branch 'hotfix/3960' into develop
Forward port #3960
ce948ab
@weierophinney weierophinney referenced this pull request from a commit in zendframework/zend-uri
@weierophinney weierophinney Merge pull request zendframework/zf2#3960 from jvandemo/hotfix/zend-u…
…ri-late-static-binding

Update toString() to use late static binding for encoding methods
74f27f1
@weierophinney weierophinney referenced this pull request from a commit in zendframework/zend-uri
@weierophinney weierophinney Merge branch 'hotfix/3960' 7dfef7f
@weierophinney weierophinney referenced this pull request from a commit in zendframework/zend-uri
@weierophinney weierophinney Merge branch 'hotfix/3960' into develop 99ff9de
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on Mar 5, 2013
  1. Update toString() to use late static binding for encoding methods

    Jurgen Van de Moere authored
    Change-Id: I470379b8527852d5f36145c88ab05cbb51582103
This page is out of date. Refresh to see the latest.
Showing with 3 additions and 3 deletions.
  1. +3 −3 library/Zend/Uri/Uri.php
View
6 library/Zend/Uri/Uri.php
@@ -359,17 +359,17 @@ public function toString()
}
if ($this->path) {
- $uri .= self::encodePath($this->path);
+ $uri .= static::encodePath($this->path);
} elseif ($this->host && ($this->query || $this->fragment)) {
$uri .= '/';
}
if ($this->query) {
- $uri .= "?" . self::encodeQueryFragment($this->query);
+ $uri .= "?" . static::encodeQueryFragment($this->query);
}
if ($this->fragment) {
- $uri .= "#" . self::encodeQueryFragment($this->fragment);
+ $uri .= "#" . static::encodeQueryFragment($this->fragment);
}
return $uri;
Something went wrong with that request. Please try again.