# How to get the full path instead of basepath

**URL:** <https://discourse.slimframework.com/t/how-to-get-the-full-path-instead-of-basepath/2596>\
**Category:** Questions\
**Created:** [August 19, 2018, 2:27pm UTC](https://discourse.slimframework.com/t/how-to-get-the-full-path-instead-of-basepath/2596 "2018-08-19T14:27:47Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Niels](https://avatars.discourse-cdn.com/v4/letter/n/ebca7d/32.png) [@Niels](https://discourse.slimframework.com/u/Niels)\
**Post date:** [August 19, 2018, 2:27pm UTC](https://discourse.slimframework.com/t/how-to-get-the-full-path-instead-of-basepath/2596/1 "2018-08-19T14:27:47Z")

</div>

Hi,

How to resolve the pathFor() into a full path instead of just the basepath.

thanks

---

<div class="post-metadata">

**Author:** ![tflight](https://yyz2.discourse-cdn.com/flex030/user_avatar/discourse.slimframework.com/tflight/32/1205_2.png) [@tflight](https://discourse.slimframework.com/u/tflight)\
**Post date:** [August 20, 2018, 12:52am UTC](https://discourse.slimframework.com/t/how-to-get-the-full-path-instead-of-basepath/2596/2 "2018-08-20T00:52:50Z")

</div>

There really isn’t a built in way to handle this. See the following for some discussions about it and some possible workarounds.

> <https://github.com/slimphp/Twig-View/issues/101>

> <https://github.com/slimphp/Twig-View/pull/20>

> <https://github.com/slimphp/Slim/issues/1326>

---

<div class="post-metadata">

**Author:** ![Niels](https://avatars.discourse-cdn.com/v4/letter/n/ebca7d/32.png) [@Niels](https://discourse.slimframework.com/u/Niels)\
**Post date:** [August 20, 2018, 7:25am UTC](https://discourse.slimframework.com/t/how-to-get-the-full-path-instead-of-basepath/2596/3 "2018-08-20T07:25:25Z")

</div>

Thanks, yes i did read those before. but did not found those back when i needed them.  
I dont think this is an issue of the renderers like twig-view, but a issue in slim it self.

however after some code reviewing i found that the uri class has also the Method getBaseUrl() in my opinion that should be used to set the routers basepath. After i changed it the paths were correctly shown. everywhere.
