LOGO

Web development services fast secure and SEO optimized by VertixWeb

Email:mr.wangweb@gmail.com

Get a Proposal
Get a Proposal
Contact Us

允许在WooCommerce的分类描述里面插入html代码和图片


WooCommerce产品分类可以设置分类描述,部分主题会在前台调用显示分类描述内容,不少外贸网站都在通过使用分类描述来做页面SEO优化,但是默认情况下WooCommerce的分类描述只支持纯文字,不能使用html,也不能插入图片,我们可以通过下面的代码来实现WooCommerce分类描述支持html代码。

/**
* Allow HTML in term (category, tag) descriptions
*/
foreach ( array( ‘pre_term_description’ ) as $filter ) {
remove_filter( $filter, ‘wp_filter_kses’ );
if ( ! current_user_can( ‘unfiltered_html’ ) ) {
add_filter( $filter, ‘wp_filter_post_kses’ );
}
}

foreach ( array( ‘term_description’ ) as $filter ) {
remove_filter( $filter, ‘wp_kses_data’ );
}

来源地址:https://woocommerce.com/document/allow-html-in-term-category-tag-descriptions/

另外还有一款插件没测试,感兴趣的可以试试看:Allow HTML in Category Descriptions

分类添加html权限

之后分类描述里面通过html代码就可以插入图片了。

Author:vertixweb    View: 227 Secondary    Update:2025-06-06

Home>WooCommerce>允许在WooCommerce的分类描述里面插入html代码和图片
E-commerce Independent Website Setup Solution

2025-06-06Cross-border e-commerce tile product WordPress + WooCommerce independent site construction website customization and development solution

2025-06-06Cross-border E-commerce WordPress + WooCommerce Customized Website Development Service Solution for the Apparel Industry Independent Site

2025-06-06Cross-border E-commerce WordPress + WooCommerce Office Renovation Independent Site Customization and Website Development Service Proposal

2025-06-06Cross-border e-commerce WordPress + WooCommerce fermented food brewing company independent site custom website development services

2025-06-06Custom WordPress + WooCommerce Standalone Website Development Solution for Cross-Border E-Commerce in the Russian Market

2025-06-06End-to-End AI Solutions for Cross-Border E-commerce

2025-06-06Southeast Asia market cross-border e-commerce WordPress + WooCommerce independent station website construction and customized development solution

2025-06-06Cross-border e-commerce independent site for the Japanese market: Custom WordPress + WooCommerce website development solution

2025-06-06Customized Website Development Service Solution for Cross-border E-commerce Independent Sites of Optical Measuring Instruments

Marketing Optimization (MO) Solutions

2025-06-06DeepSeek Custom-Tuned Precision Translation & Multilingual Website Development Services

2025-06-06Conversion Rate Optimization (CRO) Plan

2025-06-06End-to-End AI Solutions for Cross-Border E-commerce

2025-06-06Custom website development with DeepSeek for independent sites

2025-06-06Marketing Optimization (MARQ) Solution

2025-06-06Search Engine Algorithm Optimization and Core SEO/SEM

2025-06-06Cross-border e-commerce independent site full-stack development and customization

2025-06-06Cross-border e-commerce platform onboarding services

2025-06-06Brand Marketing Optimization (BMO)

Custom Theme Advantages vs. Template Theme
  • Comparison Dimension Custom Theme Generic Template Theme
  • Uniqueness 100% original design, avoiding homogenization Potentially used by hundreds of websites
  • Performance Optimization On-demand coding, no redundant code Contains a large amount of useless functional code
  • Functional Fit Perfectly matches business requirements Requires compromise or complex modifications
  • SEO Foundation SEO optimized at architectural level Generic SEO structure with limited effectiveness
  • Maintenance Cost Clean code, easy to maintain Complex nesting, difficult to maintain
  • Scalability Predefined interfaces for easy expansion Expansion limited by template constraints
  • Loading Speed Streamlined code for faster speed Redundant features slow down performance
  • Brand Image Enhances brand recognition Difficult to establish unique identity

Free application for your personalized plan


Contact Us
Website Construction
Performance Marketing Enhancement Suite(MO)

message x - -
Contact Us

Apply for your exclusive plan for free

Later Consultation

Online Consulting