📜  Woocommerce 按产品 ID 获取图片库 - PHP 代码示例

📅  最后修改于: 2022-03-11 14:53:36.435000             🧑  作者: Mango

代码示例1
get_gallery_image_ids();

    foreach( $attachment_ids as $attachment_id ) 
        {
          // Display the image URL
          echo $Original_image_url = wp_get_attachment_url( $attachment_id );

          // Display Image instead of URL
          echo wp_get_attachment_image($attachment_id, 'full');

        }
?>