Donate. I desperately need donations to survive due to my health

Get paid by answering surveys Click here

Click here to donate

Remote/Work from Home jobs

Implement rails paperclip code in html template

I have a theme, and I need to add images to it through paperclip. I used paperclip to upload the images. My Implementation is:

<!-- start portfolio section -->
<section class="wow fadeIn">
    <div class="container">
        <div class="row">
            <div class="col-md-12 no-padding xs-padding-15px-lr">
                <div class="filter-content overflow-hidden">
                    <ul class="portfolio-grid work-3col hover-option4 lightbox-gallery gutter-small">
                      <% @portfolios.order('created_at DESC').each do |portfolio| %>
                        <li class="grid-sizer"></li>
                        <!-- start portfolio item -->
                        <li class="grid-item web branding design wow fadeInUp">
                            <%= link_to image_tag portfolio.image.url %>
                                <figure>
                                    <div class="portfolio-img bg-extra-dark-gray">
                                      <%= link_to image_tag portfolio.image.url, class: "project-img-gallery" %>
                                    </div>
                                    <figcaption>
                                        <div class="portfolio-hover-main text-center">
                                            <div class="portfolio-hover-box vertical-align-middle">
                                                <div class="portfolio-hover-content position-relative">
                                                    <i class="ti-zoom-in text-white fa-2x"></i>
                                                </div>
                                            </div>
                                        </div>
                                    </figcaption>
                                </figure>
                        </li>
                        <!-- end portfolio item -->
                    <% end %>
                    </ul>
                </div>
            </div>
        </div>
    </div>
</section>
<!-- end portfolio section -->

When the images are uploaded, the images do not become adaptive. The slider zoom doesn't show an image, and it shows two images instead of one.

Please help. It would be great if someone could look into it.

Comments