How to automatically add image watermarks in Imperial CMS
How does Empire CMS automatically add image watermarks? The following article will introduce to you how EmpireCMS automatically adds image watermarks. It has certain reference value. Friends in need can refer to it. I hope it will be helpful to everyone.
Related recommendations: "Empire cms tutorial"
When uploading images to Imperial CMS, let the program automatically add watermarks. The principle is Let the watermark checkbox where you upload pictures be checked by default!
First, when inserting our own pictures into the text, generally speaking, it is 100% required to add a watermark. Therefore, I automatically checked Add Watermark on the editor so that I don’t have to manually check it every time.
The most comprehensive solution for automatically adding image watermarks to Imperial CMS 1.png
Modification method:
1. Find the file e/admin/ecmseditor/infoeditor/epage/TranImg.php
2. Find
3 and change it to
. However, there is a situation where when the image size is very small, such as when the width or height is less than 400px, a watermark is added at this time, and the watermark will cover part of the image content. , resulting in poor usability. Therefore, at this time, manually check the check box for adding watermark and remove it. In fact, it is best to use a program to judge the size to decide whether to add or not. It is easy to forget the crude method of manually removing the check box.
Two, sometimes we can insert pictures from other people’s websites into the text. But for high operation efficiency, you can directly paste the pictures from the picture website, and then check "Remotely Save Pictures" at the bottom of the editor, and also check the watermark check. In this way, when saving the article, the program will automatically download → upload → add watermarks to the pictures on other people's websites. This effect is the same as uploading pictures manually.
The most comprehensive solution for automatically adding image watermarks to Empire CMS 2.png
Modification method:
1. System settings→Manage data table→Select article system or news system→Manage fields→News text ( newstext) → Modify
2, find
3, and change it to
3. There is also a setting for adding watermarks, as shown below:
Empire CMS is the most comprehensive in automatically adding image watermarks Solution 3.png
There are three scenarios for opening this pop-up window. Each scenario is analyzed separately:
1. Click to open from the title image. Some articles need to upload a title image, also called a thumbnail image, or a header image. We usually crop pictures of this size using PS. The original size of the picture is relatively small, so there is no need to add a watermark. Therefore, it is better to uncheck the watermark option by default.
2. In the first point, click Image Upload on the editor, then on the pop-up window that opens, click "Browse Server" again, and then open the pop-up window. We generally do not require editors to upload new images in this way. This is only suitable for selecting already uploaded images.
3. When uploading column thumbnails on the column information modification page. Since it is a thumbnail, the size is also very small, and it is not suitable for automatic watermarking.
Therefore, it is best not to automatically check the watermark option on the control for uploading the title image. If you have to do:
1. Find the file /e/admin/ecmseditor/file.php
2. Find
3. Modify it to
The above method is based on your own choice use.
For more programming-related knowledge, please visit: Programming Teaching! !
The above is the detailed content of How to automatically add image watermarks in Imperial CMS. For more information, please follow other related articles on the PHP Chinese website!

Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

AI Hentai Generator
Generate AI Hentai for free.

Hot Article

Hot Tools

Notepad++7.3.1
Easy-to-use and free code editor

SublimeText3 Chinese version
Chinese version, very easy to use

Zend Studio 13.0.1
Powerful PHP integrated development environment

Dreamweaver CS6
Visual web development tools

SublimeText3 Mac version
God-level code editing software (SublimeText3)

Hot Topics



The mobile settings of Empire CMS are located in the "Mobile Template" of the "Template Management" module. The specific steps include: enabling the template, selecting the application channel, editing the template content, and saving the settings.

The Empire CMS sitemap can be found by accessing the config.inc.php file and checking the dositemap settings. If set to "on", sitemap is enabled. The sitemap path is located in the sitemapurl setting and can be accessed via a browser or downloaded via FTP.

The ideal location for the Empire CMS template file is /e/template/default/skin/default/. Secondly, it can also be placed in /e/data/skins/ and /e/skin/. You need to pay attention to maintaining the folder structure and setting file permissions. and regular backups.

The Imperial CMS database configuration file is located in the website root directory e/config/db.inc.php. It contains the following configuration information: $dbhost: database server address $dbuser: database user name $dbpass: database password $dbname: database name $dbport :Database port $dbcharset: Database character set

Empire CMS template download location: Official template download: https://www.phome.net/template/ Third-party template website: https://www.dedecms.com/diy/https://www.0978.com.cn /https://www.jiaocheng.com/Installation method: Download template Unzip template Upload template Select template

The automatic publishing interface of Empire CMS is located at /e/api/web/postinfo.php. The usage steps are as follows: visit /e/api/web/postinfo.php address and use HTTP POST to submit the article title, column ID, category ID, author and article The content and other data interfaces will return a response in JSON format, which contains the publishing results and article ID.

Yes, Empire CMS is a free and open source content management system (CMS). It is a lightweight CMS that is feature-rich and easy to use. Empire CMS is licensed under the GNU General Public License (GPL), which means it is free to download, install and use. For commercial use, it offers a paid version that offers additional features and support such as ad management, online payments, and premium technical support.

The imperial cms Baidu active push plug-in is located in the root directory /e/api/baidu/push.php. The specific configuration steps are as follows: 1. Upload the plug-in file to the specified path. 2. Configure the "Baidu Active Push" option in the Imperial CMS background, including push address, API Key and push interval. 3. Get Baidu push information: Push address: https://data.zz.baidu.com/urls?site=YOUR_SITE&token=YOUR_API_KEY, API Key: log in to Baidu search resource platform to obtain. 4. Update the API Key regularly and set a reasonable push interval.
