Coder Social home page Coder Social logo

jivey / refinerycms-page-images Goto Github PK

View Code? Open in Web Editor NEW

This project forked from refinery/refinerycms-page-images

1.0 2.0 0.0 441 KB

Adds an images tab to your pages so you can format a group of images really nicely on the frontend

Home Page: http://resolvedigital.com

Ruby 100.00%

refinerycms-page-images's Introduction

Page Images Engine for Refinery CMS

About

Page Images allows you to relate one or more images to any page in Refinery which makes it really easy for you to create simple image galleries with lightbox style popups on the front end page views.

Requirements

  • refinerycms >= 2.0.0

Features

  • Ability to select one or more images from the image picker and relate them to a page
  • Reordering support, simply drag into order
  • Optionally include captions with each image.

Install

Add this line to your applications Gemfile

gem 'refinerycms-page-images', '~> 2.0.0'

Next run

bundle install
rails generate refinery:page_images
rake db:migrate

Now when you start up your Refinery application, edit a page and there should be a new "Images" tab.

Enable Captions

You can enable captions using an initializer containing the following configuration:

Refinery::PageImages.captions = true

Usage

app/views/refinery/pages/show.html.erb

If you don't have this file then Refinery will be using its default. You can override this with

rake refinery:override view=refinery/pages/show
<% content_for :body_content_right do %>
  <ul id='gallery'>
    <% @page.images.each do |i| %>
      <li>
        <%= link_to image_tag(i.thumbnail("200x200#c").url), i.thumbnail("900x600").url %>
      </li>
   <% end %>
  </ul>
<% end %>
<%= render :partial => "/refinery/content_page" %>

Screenshot

Refinery CMS Page Images Screenshot

refinerycms-page-images's People

Contributors

akselsson avatar bobbus avatar bramjetten avatar cerebroso avatar djones avatar ghoppe avatar jamesantrobus avatar koa avatar kovalevsky avatar mhaylock avatar mirosr avatar nowaterlili avatar palodelincak avatar parndt avatar peterberkenbosch avatar phiggins avatar simi avatar skeller1 avatar soupmatt avatar ugisozols avatar wakeless avatar

Stargazers

 avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.