In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-17 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/02 Report--
Editor to share with you how to use WordPress built-in picture warehouse to make thumbnails. I hope you will gain a lot after reading this article. Let's discuss it together.
How to use WordPress built-in image warehouse to make thumbnails?
WordPress is not only a blog, most of the time WordPress is also used as a CMS (content management system). Bloggers like to add thumbnails of a uniform size to each article, especially information platforms. One of the more common processing methods is to insert pictures into the article with custom field, upload small images of the same size, or use tools such as phpThumb to generate thumbnails.
Since the beginning of WordPress, multimedia capabilities have been greatly improved, and more and more people are using WP's built-in photo warehouse. For these users, it is not so difficult to make thumbnails. When uploading an image, a small image of 150x150 size is generated by default (if the height / width of the image is not enough 150px, use the original height / width). Then we can make full use of this feature and add this picture to the article list as a thumbnail. This has its own advantages and disadvantages, the advantage is simple, intelligent (do not have to enter thumbnails every time), the disadvantage is the consumption of server traffic.
Okay, what you need to do now is to extract the small image generated by the upload and place it in the appropriate location of the article. I created a file thumb.php, image acquisition and call processing together, the contents of the file are as follows.
The code is as follows:
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.