WordPress不支持svg/ico/webp上传怎么办?

上传的时候提示以下错误:

上传失败。抱歉,由于安全原因,这个文件类型不受支持。

今天追格小编教你不用WordPress插件即可搞定该问题,其实最早也分享过《WordPress怎么上传SVG图片到媒体库之Safe SVG插件》,我们还是在现有WordPress模板函数文件functions.php中,添加以下代码即可:


add_filter(‘upload_mimes’, ‘tbi_upload_mimes’);
function tbi_upload_mimes($mimes = array()) {
$mimes[‘svg’] = ‘image/svg+xml’;
$mimes[‘webp’] = ‘image/webp’;
$mimes[‘ico’] = ‘image/x-icon’;
return $mimes;
}

【免责声明】本站提供的资源,都来自网络,版权争议与本站无关,所有内容及软件的文章仅限用于学习和研究目的。不得将上述内容用于商业或者非法用途,否则,一切后果请用户自负,我们不保证内容的长久可用性,通过使用本站内容随之而来的风险与本站无关,您必须在下载后的24个小时之内,从您的电脑/手机中彻底删除上述内容。如果您喜欢该程序,请支持正版软件,购买注册,得到更好的正版服务。侵删请致信E-mail:nianhua@88.com

猜你喜欢
发表评论

电子邮件地址不会被公开。 必填项已用*标注

评论信息

สล็อตออนไลน์回复2021-01-30 15:44

Incredible! This blog looks exactly like my old one! It's on a completely different topic but it has pretty much the same layout and design. Outstanding choice of colors!

Clothing Manufacturers回复2021-02-04 05:04

Remarkable things here. I am very happy to peer your post. Thanks a lot and I'm having a look forward to touch you. Will you please drop me a mail?

Nursing Papers回复2021-02-07 21:57

Fastidious respond in return оf thiѕ query witһ firm arghuments annd explaining thе whole thing on the topic of tһat. Take a look аt my blog: Nursing Papers

Bisnis HDI回复2021-02-12 22:46

magnificent issues altogether, you ϳust won a neѡ reader. Wһat might үou recommend abgout ʏour puut up that you made ѕome ɗays ago? Any positive? Hеre iѕ my web page; Bisnis HDI

Best University In Indonesia回复2021-02-24 04:43

I blog quite often and I genuinely thank you for your information. This article has truly peaked my interest. I will take a note of your blog and keep checking for new details about once a week. I opted in for your Feed as well.

פרסום דירות למכירה בחינם回复2021-02-26 21:32

many thanks a whole lot this web site is definitely formal along with informal

best university in indonesia回复2021-03-08 14:12

Keep on writing, great job!

situs s128回复2021-03-09 01:08

Right away I am going to do my breakfast, later than having my breakfast coming again to read more news.

Fat Freezing Sydney回复2021-03-14 15:55

Also known as low-level laser therapy (LLLT), photobiomodulation is a medical technique that utilizes LLLT in the form of infrared light that produces a cell's mitochondria to release Fat Freezing Sydney without any change to diet and exercise and without causing cellular damage. This is because the cells will undergo an organic process called apoptosis - also referred to as natural cell death. This method is probably the better methods designed for transforming the way a person looks because it is done in the simple and effective manner.

Take care of yourself回复2021-03-16 10:02

When I originally commented I seem to have clicked the -Notify me when new comments are added- checkbox and from now on whenever a comment is added I recieve four emails with the exact same comment. Is there a means you are able to remove me from that service? Thanks!

agen idn poker回复2021-03-27 12:46

What's up to every body, it's my first visit of this website; this weblog includes remarkable and truly good data designed for readers.

blown glass repair回复2021-04-03 21:55

I think this is one of the most significant information for me. And i'm glad reading your article. But wanna remark on some general things, The web site style is perfect, the articles is really excellent : D. Good job, cheers Feel free to visit my web site: blown glass repair

double glazing windows回复2021-04-04 03:28

WOW just what I was looking for. Came here by searching for double glazing windows window glazing

revs回复2021-06-09 06:11

724559 76810This style is steller! You clearly know how to keep a reader amused. Between your wit and your videos, I was almost moved to start my own weblog (properly, almostHaHa!) Wonderful job. I actually enjoyed what you had to say, and much more than that, how you presented it. Too cool! 196326

home sensory gym回复2021-06-11 06:35

315938 319848Id need to consult you here. Which is not some thing Its my job to do! I spend time reading an article that may get individuals to believe. Also, numerous thanks for permitting me to comment! 512665

Jamespeaft回复2021-06-12 22:15

Koh Samui is an ideal place for exploring yoga due to the outstanding natural beauty of the island. Most of Koh Samui is still considered unspoiled and unpolluted. Time on Koh Samui is an opportunity to relax, unwind, explore and focus on yourself. Enjoy the natural energy of palm trees, white sand, purple sunsets, turquoise waters, dense jungle, and exotic waterfalls. Despite being so easily accessible, Samui remains an idyllic island in the sun. Koh Samui is easily reached via an increasing number of direct international flights and over a dozen daily 1-hour flights from Bangkok. Arrive easily with a direct flight from any Asian hub on Bangkok Airways. Our award winning airport will receive you with a selection of shopping and eating options making flying in or out of Samui a breeze. If you’re traveling on a budget, and feeling brave, you can also reach the island via ferry from the mainland Thai city of Surat Thani. Be sure to check ferry times as the schedules are sometimes limited. Vikasa is just a fifteen minute drive from the Samui Airport. Airport pick-up is provided but not complementary for all guests, please for more information get in contact with us. https://vikasayoga.com/ Vikasa Yoga retreat in Thailand is much more than just a hotel with yoga. Vikasa Yoga Re­treat is a transformational, inspiring, and life-changing experience and one of the most reputable places to learn and practice yoga in Thailand. Our rooms are modest, yet comfortable and clean. The landscape and the surroundings are absolutely stunning, there are no words to describe them. You will have to climb a lot of stairs, but the view from the top is so worth it. You might make discoveries here that will create a major shift in your consciousness and even be the beginning of a major change in your lifestyle. And you will definitely meet some amazing people and make some new friends for life.