cant add template to cakephp 2 - css

I am trying to add a template to cakephp 2. The website is called Calm and is found from the link below. My issue is it isnt loading properly. The instruction were to simple place the files in the correct directory BUT it isnt that simple. I download the file and in webroot
I place index.html in the view.layout and call it test.ctp
I place the style.css in /css
I place all the Js file in /js
I change all the image paths to just "images/"
The layout does load BUT none of the images load and I suspect the js doesnt work
http://www.cakephpexpert.com/blog/free-cakephp-templates

rename index.html to index.ctp, default cakephp image directory is '/img', if you want use your own, try start path with slash```$this->Html->image('/images/your.jpg')``

Related

Why does my image not appear on my website

I have been trying to figure this out for sometime now. When I execute my website my images will not upload. As I can see the file on the page
enter image description here
It seems like you have index.html in the same folder as your images. You can either remove images/ from your src='...' or move all of your images into the images folder and add images/ to href='favicon.ico'.
hope that helped.
It looks like your PNG files are stored in the same directory as the HTML, not inside the images/ directory (as you probably intended). Try moving the images inside that folder.
TRY THIS "mountain.png" IF index.html is in the images folder but that is wrong though OR place your index.html out of images folder and add src="./images/mountain.png"

CSS and img dont read on Github

I'm trying to upload one project on github but CSS and img wont read.
I have tried to upload it 2 times, and checked that files names is written with small letters and are the same in the name of the file and the same in the html code but it still wont work.
Site was build using bootstrap, it is first time for me using BS so i'm not sure if it is because of that.
I am attaching link to a site and link to my repositorie on github. are you able to see what problem is?
Link to a site:
https://veljko-premovic.github.io/Tindog/
Link to repositorie:
https://github.com/Veljko-Premovic/Tindog
thank you in advance
Veljko
You are serving your images from a folder called images, but there is not such a folder.
The same with CSS, you are serving your styles.css from a “css” folder that is non-existent in your Github repo.
Either create those folders and add the images and CSS in them, or in every “src=“, remove the folder name.
Your paths are wrong, they all point to images/something.png but the images are in the same root folder as index.html so it should just be
<src img="something.png">
same for the css

Can't find Wordpress Footer image url

I've been teaching myself Wordpress theme development and have a custom made theme on my website(made by another dev a while ago). I want to be able to download the footer background image but I can't seem to find the correct url for it. In the Style.css file the footer background image is declared as
background: url(images/layout/bg-footer-boards.jpg)
But mysite.com/images/layout/bg-footer-boards.jpg, mysite.com/wp-content/images/layout/bg-footer-boards.jpg, and mysite.com/themes/mytheme/wp-content/images/layout/bg-footer-boards.jpg all give me 404's. I think this is just something with the file path that I'm missing but any help would be much appreciated!
Css url() is relative to the file rather than the webroot.
So images/layout/bg-footer-boards.jpg
refers to a folder called images/ located in the same folder as your .css file.

Rails: Stylesheet/view issue? Nothing is showing on the screen although there is source code when viewed in browser

I have a rails app with many partials for one view, each partial is a section in the view (one paged website).
I have put all my assets in the correct places etc.
below is a screenshot of how the actual page should look (outside of rails) (header, then section one which you can see, and there are sections below etc).
However this is how it is showing when done in rails
No images are shown for some reason, nor any content.
When I do not include the style sheet, all the content (writing) shows fine. When I include the stylesheet, everything disappears, its all white. However there are content there because I am able to scroll up/down.
Below is a screenshot of the structure of my files
I basically have all my images inside the image folder, but there are subfolders inside the image folders.
so:
assets (folder)
images (folder)
section_1 (folder)
image.png (file)
in my css, because my css files are inside the stylesheets folder, I call my urls as follows:
background-image:url("../images/section_1/image.png");
As for my views, it is basically one view which renders out each section (partial).
Try background-image:url("section_1/image.png");
This works in my rails project. However, I'm using compass, so it might be different.
I know what the problem is. But I still have one more problem.
The solution.
When calling an image from anywhere, even if you have a sub directory like I have, you simply call the url as follows:
background-image:url("assets/header/header_bg.png")
So you basically leave out the images folder for some reason.
The problem I still have is a routing issue.
In my assets folder I have a folder named fonts.
Inside this folder I have a number of folders, with different fonts in each folder (.eof,.ttf.svg) the usual font files.
When I type in the exact url of where these files are stored I get a routing error.
I also have a file called fonts.css in my stylesheet folder.
In the url if i put localhost:3000/assets/fonts which is the folder of the fonts I get a routing error.
Is there anyway in the routes file can I route the application correctly?
Both for the images and for the fonts?

CSS Changes, Updates in ASP.NET Theme Does Not Show Up

I thought it may be cached, but for some reason that I don't know the changes I make in CSS file that is located in application theme does not show up. If I take that change and put in a CSS file outside of theme folder, let's root or a new folder, it does show up. This is a ASP.NET 4.0 application. Not sure where to look for the solution. Please advise.
Don't just put the Theme folder, create a sub folder and put under it. It is better to name both sub-folder and css file same.

Resources