Re-doing changes from @sergiomandrake, which were inadvertently undone by @WillemPaling's updates

Adds the $ this->url(); correction of the path when the application changes location

Signed-off-by: Joshua Paling <joshua.paling@gmail.com>
Replaced spaces with tabs - and make NO OTHER CHANGES in this commit.

Signed-off-by: Joshua Paling <joshua.paling@gmail.com>