Use of the file to save | Storage location |
---|---|
Files prepared by the developer | app/assets/under images |
File uploaded by the user | Under public |
html.erb
# app/assets/images/logo.For png
<%= image_tag 'logo.png' %>
<img src="/assets/logo.png " alt="" >
html.erb
# public/logo.For png
<%= image_tag '/logo.png' %>
python
// app/assets/images/logo.For png
h1 {
background-image: image-url('logo.png')
}
Recommended Posts