Remove prefix from url

Benjamin Chew asked on March 14, 2018 10:38

I saw that some of my resource path seems to have prefix some does not have

for example,

some css file is loaded with following path


some css and js file is loaded with the following path


i would like to check how do i make it such that all the resource are loaded with the path that is without /Site?

for example


Recent Answers

Rui Wang answered on March 14, 2018 14:02

From Kentico side, if you upload images into media library, then the path would be something like .com/sitecodename/media/libraryname/filename.png

For CSS and JS that are managed through CMS, there is not prefix for the site name.

If you want to manager CSS and JS directly in file system, then you can put them under /css or /js folder like traditional website.

0 votesVote for this answer Mark as a Correct answer

Brenden Kehren answered on March 14, 2018 14:42

First ensure your website is setup properly in IIS.

Secondly, after you've corrected/verified how your site is setup make sure you modify your urls. I'm guessing they are hard coded.

Lastly, make the URL relative OR use a macro to get the correct absolute URL. {% GetAbsoluteURL("/css/some.css") %}

1 votesVote for this answer Mark as a Correct answer

   Please, sign in to be able to submit a new answer.