Ueditor Editor to implement editor adaptive width solution

Source: Internet
Author: User

Ueditor Baidu Rich Text Editor's Initialframewidth property, the default value is 1000.

The screen width cannot be adaptive. Figure 1:

At the beginning, I set the initialframewidth=null directly. The effect is shown in Figure 2:

This ueditor Baidu Rich Text editor gets the screen width at the first load and assigns the value to the Initialframewidth property.
It's true that you can fit the screen width the first time you load it, but it seems to be a little over the width, over the gray bar. And here's another question:
When you change the size of the browser, there is a serious typographical bug.
Because it will not be adaptive to width. So you'll find the editor width overflow. Figure 3:


Solution:


1. Open/ueditor/ueditor.config.js
Find the Initialframewidth property, the default value is 1000. That's initialframewidth:1000.
Change the value to ' 100% ', which is initialframewidth: ' 100% '
After saving, refresh the browser and see ...


The effect is shown in Figure 4:

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.