Imperial CMS Tutorial: Empire CMS on the list page use the SYS_RESIZEIMG function to automatically generate thumbnails of different sizes

Source: Internet
Author: User

Let's talk about ecms7.0 's sys_resizeimg, this function.

Here's how to use the list page

Tick the application code on the right! Such as:

For example, your original list page loop content code is:

<li><a href= "[!---titleurl--]" >[!---title--]</a></li>

Now you have to enter it in the box below

if ($r [Titlepic]) {$tpic =sys_resizeimg ($r [titlepic],120,80,1, ');} else {$tpic = "e/data/images/notimg.gif";} $listtemp = '<Li><src= "'. $tpic. '" ><  href= "[!---titleurl--]">[!---title--]</a ></ Li >';

Where 120,80 is the height of the thumbnail width you like to generate! You can create thumbnails of different sizes on different list pages!

Imperial CMS Tutorial: Imperial CMS automatically generates thumbnails of different sizes using the SYS_RESIZEIMG function on the list page

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.