Ruby On Rails CMS inspired by DjangoCMS [closed] - ruby-on-rails

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 7 years ago.
Improve this question
I need to choose and customize a Ruby CMS (based on Ruby On Rails preferably) for a couple of pretty large web sites. I know Radiant CMS, Refinery CMS, and Locomotive are the most famous CMS in rails, but none of them include all the features I need. Here are the main non trivial features that are (sometimes) missing in those CMS :
Page main content : Each page main content (each menu item) can display :
A list of articles of a "category" (like a blog)
An individual article extracted from a category
An individual page created with a WYSIMYM editor (this is the basic functionality of RefineryCMS for instance)
Links (external or internal resources in the library, like an uploaded document)
Custom page that require specific development (subscriptions forms,... classic rails controllers)
Template management :
I should be able to reuse "templates" across multiple pages. For instance, a template could be a layout that have a couple of "Placeholders", like one "main placeholder" (that will contains the main content of a page), and a "sidebar placeholder". When an admin build a new page in the admin interface, he should be able to select the template he will use.
The placeholders of a template, just like a page, are editable in the admin (ex: the content of the sidebard). All the pages that use this template get updated of course.
RQ : This template / placeholder feature exists partialy in DjangoCMS
"Plugins" : the content of the placeholders should be filled with custom plugins that I can reuse on multiple templates. For instance, I could code a Twitter plugin that displays the last 10 tweets from a user (a parameter of the plugin). So in the template edit page, I could add this plugin inside the "side placeholder".
This notion of plugin exists for instance in DjangoCMS
WYSIWYM / WYSIWYG editor : in the content of an article or a page created with the WYSIWYM editor, I should be able to
Insert a link to a internal resource form the librairy, for instance a PDF document uploaded previously
Insert internal images form the internal librairy
Insert slide shows of images
Insert videos from Youtube
Multisite : ressources like a list of articles (a categorie of articles), documents, can be displayed on pages of different sites on different domains. Everythings is managed from a simple admin site
Multilingual (articles / pages can be translated)
What would be your choice and why ?
Should I rebuild a custom solution from scratch ?
Did anybody implement one of those features (in Radiant CMS, Refinery CMS, or Locomotive for instance) ?
Thanks for any help or advice on this !

I suggest you give ComfortableMexicanSofa a try. While it may not have every single feature you want, integrating those are pretty trivial.
I'd say there's no CMS with better templating capabilities than Sofa.
Plugins, helpers, partials, snippets... whatever you want to call them can be inserted anywhere.
This CMS comes with Wymeditor for richtext editing. It's not fully integrated yet, so it's not super user-friendly in terms of attaching existing files but I'm working on improving it.
Multisite. Yes, sites can also be attached to a locale. So you can have http://en.example.com and http://fr.example.com
There's also a Wiki that may answer some of your questions.
I'm the author btw. Feel free to ask anything.

Related

How to create a "guided tour" in Rails app? [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 3 years ago.
Improve this question
I'm looking for ideas, best practices, gems (if such exist) that would allow me to easily create a guided tour for an existing Rails 4 web application.
I would like any new user that signs up to be greeted with a welcome message that explains some of the site's features. When they click "Next", they should go to another page (say, projects list) where another explanatory message appears. Next step would be yet another page (e.g. tasks list) with message and so on... I'd like the explanatory messages to be as unobtrusive as possible, similar to flash messages.
The possibility to skip or hide the guided tour and start it over later would be, of course, very nice to have.
I know that I could create it "by hand" using cookies and some additional controller logic (flash messages) but wouldn't like to pollute all of the controllers with additional logic for guided tour.
I've been using Shepherd.js for the last several months in my Rails apps. I found it handles itself best of all the JavaScript tour libraries in a responsive webapp, as the mobile experience is an important part of our product. Plus, its provided themes were easy to integrate into our existing look-and-feel. (You can install the Shepherd.js rails-assets gem for easier use in the asset pipeline.)
I've since wrapped Shepherd.js into a Rails gem called Abraham to make it easier to configure tour content, track which users have seen each tour, and allow users to skip a tour for now.
Another option is IntroJs http://usablica.github.io/intro.js/, both this and Baldrick's answer are great options.
You could use the jQuery plugin Joyride for this.
I would create a controller dedicated to the guided tour that renders some of your existing views (for example '/tour/1', '/tour/2', 'tour/3', ...), but add inside the hidden html ol used by Joyride (see the doc). At the end of the tour on each page, use the Joyride callback postRideCallback to redirect user to the next page of the tour.

Allowing admin of rails site to edit html

I have the whole admin backend setup, but I need to add a feature were admins can either edit the HTML of the site, or if easier edit just the text around the site. The main idea is to have the admin edit the form labels through the backend. Was wondering which is the best direction to go with?
I've used Rails internationalization support for things like this in the past: static bits of text that admins, non-technical stakeholders, business people, etc want to tweak and tweak, and I want to enable them to do it quickly (and without bothering me to fix a typo they would)
For the being able to edit form labels you could/should use Rails Internationalization Support for form fields. Here's a super brief intro to this, but there are better documentations to dive into.
Rails Internationalization support allows for more than just storing keys in YAML files - there are few different ways to do it. There's also CopyCopter an open source admin website for internationalization keys.
As far as having non-technical people edit other parts of your site, internationalization could help here too: allowing folks to change whole phrases/blocks of text in your app.
For example, instead of hard coding, "Welcome to the site" in a .html.erb file you do <%= t :welcome %>. An admin can edit the welcome internationalization key and change it to something more appropriate, "Yar! We be welcoming you to the site" if you want to go pirate theme. Or Whatever.
It also gives you internationalization structure for free: makes it easy for admins to edit the English of the site, but you have all the infrastructure for making a French version of the site too - just get a translator to fill in French internationalization values.
Maybe you could realize that with following editor:
Github: https://github.com/jejacks0n/mercury
Demo: http://jejacks0n.github.io/mercury/
Railscasts: http://railscasts.com/episodes/296-mercury-editor (maybe outdated)

Is there anything in Node.js like scaffold in Rails? [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 7 years ago.
Improve this question
Is there any tool or framework in Node.js that allows you to create a table in the DB and generate RESTful APIs automatically like Rails?
Thanks a lot!
I guess it depends on what you want:
Rails style code generation (where it generates code for you that you can modify)
Django style semi magic where admin forms can be derived from the fields in your table/document schema.
you mean generating an API for these fields in the database, ala what grape does for Ruby -- you do some configuration and translating data to JSON and transmitting it back over the wire is taken care of for you
You have a new project and you're looking for a framework with one of these three characteristics
For the first three options there are a few related SO questions on this already:
Node.js Mongoosejs Crud scaffolding
Admin panel for Node.js and Mongoose
Is there a CRUD generator for Mongoose and Node.js and Underscore? Or a CRUD generator for a similar stack?
There are a few awesome answers in this set of links, including:
#jsalonen's answer gathering up some tools <-- mostly about generating admin UIs
#Dow's answer with some tools <-- he mentions RailwayJS (now CompoundJS), then points to some other SO questions/answers on this topic.
#bergie's answer about a module that exposes JugglingORM models as RESTful API routes automatically
Or, as #Andbdrew mentioned in the comments, there's node-restify
You could write your own generator - perhaps you could write a Cake task that would take a template file, execute some Javascript and output a view for your application. I started down this path recently myself. Certainly with the variety of technologies Node.js apps involve (different ORM choices, Javascript front ends, CSS layouts) this may make sense.
For the last option - an opinionated rapid web development Node.js framework that provides good API support, there are a few options:
#abject_error's answer, in this question, about Sails
Geddy <-- automatically provides .json versions of the data your controller specifies (depending on the request it uses this data to render HTML views or creates a JSON representation)
There's a nice slide-show on How to quickly make REST APIs with CompoundJS, so CompoundJs may fit your tastes.
I initially left these off as I assumed you may have an existing project, or didn't want to use an opinionated framework, but added them because why not.
SailsJS (https://github.com/balderdashy/sails) is exactly what you're looking for. It uses the Waterline module for simulating ActiveRecord. Just define a resource, and it will automatically create JSON endpoints for all RESTful actions, and also makes the endpoints compatible with Socket.io connections.
It's built on Express, so you can use any Connect middleware to extend it. AFAIK it's the best NodeJS framework for building API backends.
Defining a new resource is as simple as sails generate user. This will create the appropriate model and controller files, which you can then modify.
Keep in mind Sails was built with schema-less datastores in mind, so it's primary support is for MongoDB, not MySQL. I'm not sure how well (if at all) it supports SQL databases.

single heroku URL with multiple rails apps using same model / authorization from amazon cloud

Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 4 days ago.
Improve this question
I'm using Rails running on heroku. I serve assets on amazon S3. The main URL is mostly static pages. It's time to add some dynamic pages (I think I'll be using amazon for database?), forum, file management (upload/download, tagging), Interactive training, & ...etc.
My thought is to create new apps for each of the dynamic sections of the URL. This will keep slug size down and not allow people on the static pages to use resources of the other "sections" (or apps) and vice versa. So I'll have a users app, forum app, training app,...etc.
Each of these individual apps will need authentication against user accounts. No reason that each app should have individual duplicate user databases... So I'm a bit unclear on how different apps can authorize accounts against the same DB and carry "sessions" over from one app to the next. Is it as simple as ensuring each app has the same database.yml & the same models? Store my sessions into the DB? Use AJAX to call the USER app?
I Don't like that I'm going to be maintaining several repositories that contain the same layout (for consistency) and I THINK the same model & database.yml. But to maximize heroku slug and "refactor" apps it seems like it'll be worth it?
also, should each of these apps be new domains: app1.mysite.com, app2.mysite.com or just mysite.com/app1 mysite.com/app2
I've bee doing lots of learning on kicking off my first dynamic site and am looking for direction & resources to address the multiple app shared DB piece.
Thanks
In my opinion, you should create only one application and store your controllers, models and views in different directories. You will be able to use the same models along your whole site and it will be a lot more easier to maintain.
Also, your session question won't be a problem anymore, and you can organize your routes how you want.

Anyone got SEO tips for Ruby on Rails [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 8 years ago.
Improve this question
Can anyone recommend some RoR plugins and/or general sage that will help me with SEO?
I myself was searching for some guide on SEO for ruby on rails, surprisingly there was no updated/recent article on the web (this post ranks #1 in google and this is also 3 years old) as that link seoonrails is dead and other articles are written in 2010 so I went ahead and wrote a complete SEO for rails guide http://www.inboundio.com/blog/seo-for-ruby-on-rails-complete-guide/. It took me 3 days to write it (including the infographic) and I have tried to link back to railscasts and other sources where ever possible to make it more helpful.
To answer OPs questions, following gems can be used as starting point -
Friendly ID - https://github.com/FriendlyId/friendly_id
Meta Tags - https://github.com/kpumuk/meta-tags
MetaMagic - https://github.com/lassebunk/metamagic
Sitemap - http://rubygems.org/gems/sitemap or http://rubygems.org/gems/xml-sitemap
Breadcrumbs - https://github.com/lassebunk/gretel
You can further refine your rails app with following gems
Rack cache (for caching) - http://rubygems.org/gems/rack-cache
GeoCoder (for geotargeting) - https://github.com/alexreisner/geocoder
Geokit (for geotargeting) - https://github.com/geokit/geokit
Mobile fu (for better Mobile Optimization) - https://github.com/brendanlim/mobile-fu
SEO is a field by itself. But for a rails app you could use the following gems to make you site more search engine friendly.
Metamagic http://github.com/lassebunk/metamagic
Headliner https://github.com/mokolabs/headliner
Gretel for breadcrumbs http://github.com/lassebunk/gretel
FriendlyID for SEO friendly urls http://github.com/norman/friendly_id
DynamicSitemaps for generating stiemaps http://github.com/lassebunk/dynamic_sitemaps
Finally all these and a small description on how to use them could be found on this blog post http://lassebunk.dk/2011/03/09/rails-seo-pack/ by Lasse Bunk
Sorry to resurrect such an old question, but it's been on my mind too, I'll share what I came up with.
As you probably know, SEO is pretty blurry in general. But these are a few of the core things that I've discovered from my reading. But I'm no SEO whiz.
A good strong name.
Every page's title attribute should somehow be titled for its content specifically. It's also not a bad idea to ensure that it has near 60 characters. As far as getting the title to change depending up on the page, you could do something like this:
http://railscasts.com/episodes/30-pretty-page-title (the railscast is a bit dated, maybe there's a newer way to get this done?)
Rails 3 - Ideal way to set title of pages (I kind of like the look of this one.)
Create a robots.txt file
You just throw it in your public folder with something like this, assuming you want all of your pages indexed:
User-agent: *
Disallow:
Create a Sitemap and submit it to Google Web Developer Tools
I just checked this one out, and it did what I wanted.
https://github.com/kjvarga/sitemap_generator
You might look at rails powered meta tags using the following gem, though, I've not used it:
https://github.com/parndt/seo_meta
And, I think that really wraps it up for rails specific things. There are so many other SEO resources out there, and so many of them are just things that you manipulate the view to accomplish, so they're not really rails questions at that point.
A few other things to think about as well, but they're not really rails specific, and mostly in your views.
Make sure your code is W3C valid
Title attributes for image tags.
Using header tags appropriately.
Don't put text in images, that's what text is for. If you want to use a pretty font, use google fonts.
Make sure you have outbound links to resources that make sense for the context of your page.
Create a printable stylesheet.
I believe the most important ingredients to SEO are:
good content and
good inbound links.
None of these can be achieved using any plugin.
See also SEO: Where do I start?

Resources