php – Add a suffix to the image in the_content()
Question
How to add a suffix address ?x-oss-process=image/auto-orient,1/quality,q_98/format,webp
to all the urls of images (except .webp) in the_content()
?
Such as:
Original: https://a.com/wp-content/uploads/123.jpg
After modification: https://a.com/wp-content/uploads/123.jpg?x-oss-process=image/auto-orient,1/quality,q_98/format,webp
form <a href="123.jpg"><img src="123.jpg"></a>
to <a href="123.jpg?x-oss-process=image/auto-orient,1/quality,q_98/format,webp"><img src="123.jpg?x-oss-process=image/auto-orient,1/quality,q_98/format,webp"></a>
0
2 years
2022-02-17T21:48:13-05:00
2022-02-17T21:48:13-05:00 0 Answers
0 views
0
Leave an answer