📜 ⬆️ ⬇️

User formatter

For a long time I have been developing websites, naturally, each site requires some kind of admin panel, and since the most important thing about the site is content (content), you need to prepare a tool for the user (resource manager) to work with content (content). Since you can’t kill stereotypes, and basically people are accustomed to working in Word (at least I have met them), a formatter is needed. I tried quite a lot of formatters, I even had a crazy idea to write my own. There are a lot of problems, juzvery try to edit the text formatting to your taste, which is sometimes missing, change the font, its color (bright red letters with a green background even met), size, fills in tables and other creativity. The result was not an article, but a terrible eclectic ...

In formatters they forbade changing the format of text, tables, etc., signed their classes, etc. Everything seemed to be getting better, the result became more or less acceptable, only there was a problem with the pictures. Pictures are of different sizes, sometimes such that they break all the layout (this even sometimes happens on Habré, what can I say about managers who don’t even know that the dimensions of screen graphics are measured in pixels, not centimeters). In general, the next "terrible" problem, to train the staff is completely reluctant, my terrible rozkazni about kilobytes, download speed, the pixels do not always reach the ears of managers.

As a result, the following idea was born. What if the article is divided into several blocks. For example, a block with a picture on the left and text, a block with a picture on the right and text, a block of pictures in one row, a block of a table, a block of just text ...
A user uploading a picture indicates it on his computer, it is loaded and compressed to the desired size (and all this happens without reloading the page, since there is a technology like AJAX), the position of the picture on the pages, alignment and everything else is immediately determined.
')
Pros:


Here's a question for the Habra community: are there any similar implementations and what problems do you think may arise with the use of such a tool?

Source: https://habr.com/ru/post/43390/


All Articles