Solved thread

This post is marked as solved. If you think the information contained on this thread must be part of the official documentation, please contribute submitting a pull request to its repository.

Image and js Path

Hi

I'm kind of new to phalcon and I have som e issues access the images/javascript that I put under PATH/public/img(js)/

everything is working fine accessing the "root" (domain.com/). But when I try to access a routed site the sites get very ugly:)

From the ngnix access log i see that the file /Teams/js/plugins.js where Teams is one of my controllers. This path does however not exsist. and the path should be /js/plugins.js.

How do you fix this? In phalcon settings or using ngnix redirect in some way?

Regards André

Maybe you have somwhere setted baseurl to /Teams ?



4.1k
Accepted
answer
edited Dec '15

Hi no i don't belive that since i have the same issue for all controllers.

I did however find how to use images using .volt syntax for images, styelsheets and javasacript https://docs.phalconphp.com/en/latest/reference/tags.html#images

I just need to change all the standard HTML syntax to VOLT ones

And this is working :)