Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

createUrl() called from YiiListView problem with hierarchy categories #1

Open
holdmann opened this issue May 20, 2014 · 1 comment
Open

Comments

@holdmann
Copy link

Hi, there is very nice extension, but it doesn't work as expected view CListView(GridView).

The problem occurs in sorting and paging elements. After execution of createUrl() method, slash converts to html representation "%2F", and page throws 404 error code.

As temporary fix, I override createUrl() method in Controller.php class.

<?php
public function createUrl($route, $params=array(),$ampersand='&')
    {
        $url = parent::createUrl($route, $params,$ampersand);
        $url = str_replace('%2F', '/', $url);
        return $url;
    }
?>

Maybe I missed something when configuring, but at first glance - not :)

@ElisDN
Copy link
Owner

ElisDN commented May 26, 2014

Yes, it is known think. Yii uses urlencode() for all values. I prefer use class UrlManager (extends CUrlManager) with same code like there.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants