
如何在WordPress中添加分页符并自定义样式?
apply_filters( 'load_image_to_edit_attachmenturl', wp_get_attachment_url( $attachment_id )
load_image_to_edit_attachmenturl: 这个函数根据附件的ID返回附件的URL。它用于生成在媒体库中正在编辑的图片的URL。
编辑图像时过滤附件URL的路径。
仅当文件未存储在本地且服务器上启用了allow_url_fopen
时,才会评估筛选器。
$filepath = apply_filters( 'load_image_to_edit_attachmenturl', wp_get_attachment_url( $attachment_id ), $attachment_id, $size );