I just purchased a
wrap bootstrap template and tried to use it on a ruby on rails app. I pasted all its images files under my local
/app/assets/images folder, js files under
/app/views and all css files under
When I just clicked the html file it's working correctly. But when I tried to run localhost, it just showed the basic html files without any pictures or font styles.
Yes. I ran into this Exact problem myself recently. The way I solved this was to:
Open the downloaded WrapBootstrap template contents (example mine had various pages but two main folders Documentation and HTML). Inside of the HTML folder there should be a sub folder named assets. Copy and paster this entire folder into you public folder.
The next step which had me beating my head into the table was when you use a page of the HTML in the template the CSS and JS is all referenced in a similiar way example:
But when you place it into your application.html.erb file you need to make sure you place a leading / (slash) in front of assets like so:
So that now the assets are being referenced from an absolute path rather than a relative one.