GetmeUK / ContentTools

A JS library for building WYSIWYG editors for HTML content.
http://getcontenttools.com
MIT License
3.95k stars 395 forks source link

Question: Password protection for Сontent Tools entry #528

Open esshevelev opened 5 years ago

esshevelev commented 5 years ago

Hello! I want to use the content to be able to edit small promo sites from a couple of pages. Passed the steps of the starting lesson. Everything is working. Now I solve the problem of how to protect the button for enabling the edit mode with a password so that only the site owners can edit the page. Please share your experience with who solved a similar problem. Surely it is very frequent.

cyclaero commented 5 years ago

I solved this by using a FCGI Daemon which is addressed by Apache only for logged in admins by the way of HTTP Digest Authentication and which then injects the editing tags into the respective pages and provides the ContentTools JS and CSS as necessary. Normal users would see plain HTML pages and would have neither access to anything of the ContentTools frontend nor to the other stuff of my ContentCGI backend.

See: https://github.com/cyclaero/ContentCGI https://obsigna.com/articles/1529528376.html

And for embedding a search engine into all this: https://obsigna.com/articles/1539035906.html