Skip to content

Instantly share code, notes, and snippets.

@kalenjordan
Last active August 29, 2015 13:56
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save kalenjordan/9220802 to your computer and use it in GitHub Desktop.
Save kalenjordan/9220802 to your computer and use it in GitHub Desktop.

Edit Content over the Frontend

Background

Content editing is always a little bit of a hassle. Sometimes your team might not know where a given piece of content exists - whether in CMS Pages, Static Blocks, Product content, or static HTML.

The Idea

Give admins the ability to edit content directly through the frontend via something like a blogger-style interface (you guys remember the blogger days, right?).

The Featuh's

  • Load via AJAX after page load - only shows if the admin is viewing the page.
  • Specific pieces of content will have a data-editable HTML attribute on them.
  • Different types of content would need to be handled differently. Static CMS blocks would work differently from CMS Pages and from product attributes.
  • Not meant to be an automatic solution to edit all content across the site with no manual work. It would take some work, including possibly specific HTML attributes in page templates.
  • No WYSIWYG - when you click on a piece of content to edit it, you'd do so in some kind of raw HTMl editor. But you're only editing one piece at a time - it's not like you're looking at the whole page's HTML source at once.
  • After editing the content, it would replace the content in-page using javascript without actually saving it. This allows the admin to see what the changes will look like immediately. See whether that updated product page headline spans two lines or three lines and adjust quickly.
  • Have a button in the toolbar to actually save changes - maybe with some checkboxes to also clear cache / varnish at the same time.

Questions

Why not just use inline translation for this?

I'm pretty sure it's not compatible with FPC / Varnish, and even if it were, it would only work for translateable pieces of content - not for things like CMS blocks.

This is retarded - you're never going to build easy content management. Content management will forever be a pain and no one can change that! Rah rah rah internet rage!

Calm down there buddy.

@fooman
Copy link

fooman commented Mar 13, 2014

@SchumacherFM
Copy link

An idea for future improvements: https://github.com/microweber/microweber :-)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment