Use offline Bootstrap in root-folder from tms development server

I use Bootstrap offline for several projects on the same server. Therefore I put the downloaded content into the root-directory and change the index.html of the project to use "/bootstrap/... which works fine on the production environment.

But when I use the same index.html in development, my "/boostrap/..." folder is not found by the development-server. So I can fiddle around manually the index.html for development and production - but I guess there is a more professional way to handle this ?

Any hints ?

Thanks/Regards, Tom

If you add the files to the project, the compiler will deploy the files included in the project file automatically to the output folder.

I know, but if I do so, I have the offline Bootstrap-content in the subfolder of every project I upload to my server - I wanted to avoid that. So I decided to put the Bootstrap content in the root-folder of the server and refer to this same root-folder in the index.html file of each project. That's common I guess and works perfectly fine on the production server.
But during development with Delphi Web Core it does not work because I do not know where the TMS WEB development server has it's root-directory folder....

My solution is to use two different index.html. But this is quite unhandy...

If you have Bootstrap on your deployment server, can't you point to this Bootstrap CSS & JS files with the absolute URL of this library on your deployment server?
Then it should work when deployed as well as when you do development locally.

Hello Bruno,

that's a good idea and it works on both development and deploment server. The downside is that flexibility gets lost because of the absolute adress.

But anyhow - now I have two options to choose from that work for me.

I just wanted to make sure that I did not overlook something in project-configuration that makes it possible to use different relative locations of libraries for development and deployment.

Issue can be closed now.

Thanks/Regards, Tom

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.