Empire CMS thumbnail: Create different thumbnails in different places of the site

Source: Internet
Author: User

This article transferred from: http://blog.sina.com.cn/s/blog_4d49ba58010115sd.html

Make it easy to call different sizes of thumbnails in multiple places on your website.

Generate thumbnails of different sizes at any location on the site, depending on the source of the image.

Take smart labels for example.

Previous write title picture for

[e:loop={column ID, display number, type of operation, display only title picture, append SQL condition, display sort}]
<a href= "<?= $bqsr [titleurl]?>" target= "_blank" ><?= $bqr [titlepic]?>"/> </a>
[/e:loop]

This picture source, you can for any picture field, like Picurl and so on. The picture needs to be local.

Well, now you can.

[e:loop={column ID, display number, type of operation, display only title picture, append SQL condition, display sort}]
<a href= "<?= $bqsr [titleurl]?>" target= "_blank" > 1,')?> "/></a>
[/e:loop]

The red part produces the thumbnail size.

Empire CMS version 6.6 template added auto-generated thumbnail function, you can directly convert the title picture to the corresponding size display, the file is smaller, access faster.
(1), function syntax: sys_resizeimg (original image, thumbnail width, thumbnail height, whether to crop bentgrass image, target file name)
Original image: For example $bqr[titlepic], the destination file name is not set.

If the display system for Untitled pictures specifies a picture:

Sys_resizeimg ($BQR [titlepic],145,132,1, ')


This perfectly solves the problem of different demand thumbnails

Empire CMS thumbnail: Create different thumbnails in different places of the site

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.