Where communities thrive

  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
Repo info
  • Jun 16 03:36
    donrestarone closed #938
  • Jun 16 03:36
    donrestarone opened #938
  • Jun 06 08:41
    uzian opened #937
  • May 27 12:06
    kirichkov synchronize #935
  • May 26 18:13
    kirichkov synchronize #935
  • May 26 17:48
    kirichkov opened #935
  • May 25 19:06
    catmando opened #934
  • May 06 20:44
    Mbuckley0 opened #933
  • Apr 26 12:29
    ksza closed #932
  • Apr 26 12:28
    ksza opened #932
  • Apr 17 02:00
    nitsujri commented #925
  • Apr 17 01:59
    nitsujri commented #925
  • Apr 16 19:40
    donrestarone commented #925
  • Apr 16 03:22
    nitsujri commented #925
  • Apr 14 23:45
    donrestarone commented #609
  • Apr 04 22:59
    donrestarone commented #931
  • Apr 04 22:57
    donrestarone commented #925
  • Apr 04 22:55
    donrestarone edited #931
  • Apr 04 22:55
    donrestarone opened #931
  • Mar 29 12:20
    massongit synchronize #927
HI I want to create 404 page for cms how can I
Okay I found this comfy/comfy-blog#57
Robert Head
When I use page.label and page.url in my menu , it's always in English, even if I18n.locale is something else. label and url don't take a locale, so I'm at a loss. How do I localize the menu?
Karol Topolski

I'm kinda new in the comfortable mexican sofa world and I encountered really weird bug on rails 6.0.1. It's connected to activestorage.

I installed activestorage and I tried to upload file via CMS. It shows empty progress bar, but in the server logs there's a loop on creating and deleting activestorage. There's no progress, just endless loop of create->delete. I'm kinda lost :(.

Thank you for creating this amazing gem and thank you for your time :)

Screen Shot 2019-11-20 at 13.49.51.png
Karol Topolski
OK so I ended up uploading file via rails console and Comfy::Cms::File model. Saved with validate: false cause I had to skip file attribute presence validation. I attached manually to attachment.
Justin Gordon
Hey everybody! Big thanks for the gem! It's awesome.
Big question: we click the <> to edit the HTML in a wysiwyg, and the data saves just fine. But then if we make any edit, even to a different field, the HTML source gets all sort of <p> tags and it's no longer html. Any ideas? Should I open an issue for this?
@justin808 Please make an issue. I'm guessing that Redactor is doing something weird, but who knows.
Justin Gordon
@GBH the workaround is to only edit the HTML by adding attributes to the tags created by Redactor. My co-worker wanted to put a <style> block above the HTML. Are there any docs for what sort of limitations there are with editing the HTML?
Justin Gordon

How can I see what user did what update? Is there some glue to the current_user?


how can I update WYSIWYG editor
Is there any document for that
Hello! Does anybody know if there's an option to disallow or sanitize <script> tags entered into the WSIWYG? I had an outside security review recently and they flagged this as problematic...

I am a beginner developer.
I have been worried since yesterday. I have two pages that are content pages managed by this CMS (mexican-sofa).

I put these on the TOP page (https://example.com/
Is there a way to do that? I wrote the following code in application_controller using before_action

before_action :redirect_cms_pages

def redirect_cms_pages
redirect_cms_pages_list = ["/interviews", "/seminars"]
current_fullpath = request.fullpath
redirect_to '/' if redirect_cms_pages_list.include?(current_fullpath)


hey there! is that technically possible to create a custom tag which accepts a block argument? So it's possible to do something like that: {{ gallery-row }} image tags {{ /gallery-row }}
Tom Aranda
Is it possible to grant admin access on a page by page basis? I would like some administrators to be able to edit some pages in the site but not others. I am using CanCanCan and Devise. This is a major feature we are looking for.
hey there, I have problem when I deploy on heroku my picture disappear 😢
Any tips for me ?
Peter Albertson
I have a site with a lot of files and site admins need the ability to attach the same files somewhat often. I'm wondering if there's a reason why there's a limit on the ajax request for files in the redactor chooser?
This is from the files_controller.rb
I think because there's no pagination on that widget. Loading everything under the sun might be a bad idea.
Hi Team,
I want to call {{ cms:page:events:event_grid }} as per parent on particular layout can someone suggest me best approach ?
Stanley Liu
hi @GBH, i'm upgrading an old app to use ActiveStorage instead of Paperclip, and have almost completely set it up by now, the only issue is that now the ActiveStorage routes are inaccessible as they come after the CMS routes in priority, so I tried using your config.railties_order fix, defining ActiveStorage::Engine first, but now helper methods in app/helpers aren't being imported properly so it breaks the website. perhaps it's in :all? i'm relatively new to Rails, so wanted to understand better how to solve it
Stanley Liu
never mind, i managed to solve it by putting setting the order [ActiveStorage::Engine, :main_app, :all] as shown
Matt Polito
Hello all! Was wondering if anyone else is seeing a huge performance hit when going to a comfy page edit? It seems to be from building the page structure tree to populate the parent and redirect dropdowns.
Matt Polito
I checked the issues/pr on github but didn't notice anyone else mentioning it so thought I'd pop in here to ask
Stanley Liu

wondering whether anyone has had experience with integrating PgSearch with CMS? prior to upgrading to CMS 2.0 this code worked to allow Comfy pages to be indexed:
`module FragmentSearch
extend ActiveSupport::Concern

included do
include PgSearch
multisearchable against: :content, if: -> (record) { record.identifier == "content" }
endtrying to launch the server constantly fails with unidentified method 'has_many_attached?' despite ActiveStorage being installed I tried include ActiveStorage::Attached::Macros` but the same message still appears. help is much appreciated. TIA

Craig Hoffman
Question - My production server is running Nginx through a reverse proxy. The proxy url, for example, looks like this: https://server.example.com/hello/world. When I log in to Comfy and navigate the /admin, I see the left nav links, Site, Layouts, Pages, Etc... When hovering over the links, they do not show the correct URL. They show https://server.example.com/admin/sites. They need to show the full path such as https://exmaple.com/hello/world/admin/sites. Any idea where I can make such changes? Does this make sense?
Emmanuel Hayford
Hi all. I would like to reverse (newest blogs posts first) the order of blog entries in the admin page. How can I achieve this. I'll appreciate some directions. So on this page https://gyazo.com/05aeedba487e3f6a0411ade067577960 "Testo" should be last, "two" (which is latest) should be first. Any idea what to tweat to achieve this?
Damien Sutevski
on my CMS post, I am trying to render a partial, but it just ends up being a string:
<%= render partial: "views/comfy/blog/blogs_rail", locals: {} %>
in the layout, i have: {{ cms:partial 'views/comfy/blog/blogs_rail' }}
appreciate any guidance on this? have googled and looked around github. tried erb, tried slim, and messed around with partial content tag in my local gem.
Damien Sutevski
@siaw23 fyi, you can modify the index file for your posts to be whatever you want. then just put a date order on this: - @blog_posts.each_with_index do |post, index|
@blog_posts.order(created_at: :asc) do |post| (<--- probably this)
Damien Sutevski
@GBH any idea on my issue using partials? looks like a few other users in this chat history may have had similar issues
Damien Sutevski
@datenimperator it seems you also had this issue. the partial tag renders to ERB but doesn't get evaluated and just shows as a string once the view is rendered. how did you fix it?
Paul Bailey
Does anyone know how to stop the wysiwyg editor from stripping divs in the pages editor? I'd prefer to use the editor in the layouts page as its much nicer so if there is an easy way to switch that I'd be interested to hear too :)
I tried the coffeescript in comfy/comfortable-mexican-sofa#609 but that just broke the textarea box
is there any other way to change field name
{{ cms:page_file:other_image }}
it show Other Image
but I want to change label but keep other_image field
ex .{{ cms:page_file:other_image:name:img }}
Chris Payne
Hello, is there a way to add Ruby code to the Snippet or in the Layout content? for example, I've created a snippet called: footer-snippet and the content is: "<p>The current year is <%= Date.today.year %></p>" and then include it in my application view like "<%= cms_snippet_content('footer-snippet').html_safe %>" the current year isn't displayed, tried a fair few different combinations and couldn't find a solution.
hi everyone
I'm newbee to here this communitiy, I'm working on the migration from v1.12 to v2.0
now I wanna ask about "Javascript.js" part how v2.0 deal with it
Thanks in advance for you, appreciate your help